diff --git a/providers/smtp/tests/unit/smtp/hooks/test_smtp.py b/providers/smtp/tests/unit/smtp/hooks/test_smtp.py index 9c601fdce54f5..c3c33a0b3f372 100644 --- a/providers/smtp/tests/unit/smtp/hooks/test_smtp.py +++ b/providers/smtp/tests/unit/smtp/hooks/test_smtp.py @@ -28,10 +28,6 @@ from airflow.models import Connection from airflow.providers.smtp.hooks.smtp import SmtpHook -from airflow.utils.session import create_session - -pytestmark = pytest.mark.db_test - smtplib_string = "airflow.providers.smtp.hooks.smtp.smtplib" @@ -317,8 +313,6 @@ def test_send_mime_noauth(self, mock_smtp, create_connection_without_db): smtp_hook.send_email_smtp(to="to", subject="subject", html_content="content", from_email="from") mock_smtp.assert_called_once_with(host="smtp_server_address", port=587, timeout=30) assert not mock_smtp.login.called - with create_session() as session: - session.query(Connection).filter(Connection.id == conn.id).delete() @patch("smtplib.SMTP_SSL") @patch("smtplib.SMTP")