Skip to content

Commit

Permalink
test get_smtp_service with empty config
Browse files Browse the repository at this point in the history
Signed-off-by: joseph-sentry <[email protected]>
  • Loading branch information
joseph-sentry committed Sep 27, 2023
1 parent 8bde706 commit ed6fc14
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions services/tests/test_smtp.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,11 @@ def test_idempotent_connection(self, mocker, mock_configuration):
second_conn = second._conn
assert id(first_conn) == id(second_conn)

def test_empty_config(self, mocker, mock_configuration):
del mock_configuration._params["services"]["smtp"]
service = get_smtp_service()
assert service is None

def test_send(self, mocker, mock_configuration):
email = Email(
to_addr="[email protected]",
Expand Down

0 comments on commit ed6fc14

Please sign in to comment.