💚(ci) also save Dimail logs from E2E test runs
To help debug with Dimail interop, save logs from the Dimail container. Also fix the tests' expectations…
This commit is contained in:
@@ -182,10 +182,9 @@ def test_api_mail_domains__no_creation_when_dimail_duplicate(caplog):
|
||||
assert response.json() == {"detail": dimail_error["detail"]}
|
||||
|
||||
# check logs
|
||||
assert len(caplog.records) == 2 # 1 + new empty info. To be investigated
|
||||
record = caplog.records[0]
|
||||
assert record.levelname == "ERROR"
|
||||
assert (
|
||||
record.message
|
||||
== f"[DIMAIL] {dimail_error['status_code']}: {dimail_error['detail']}"
|
||||
== "[DIMAIL] unexpected error : 409 {'detail': 'Domain already exists'}"
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user