tests: basic: Add tests whether system users can dispatch mails
All checks were successful
Test / tests (push) Successful in 3m26s

This commit is contained in:
Thomas Preisner 2025-03-27 19:29:02 +01:00
parent 2db35aed07
commit f110705435

View file

@ -82,6 +82,19 @@ in
I'm pretending to be someotheraddress@example.com and the mailserver should reject this attempt.
''}")
with subtest("send succeeds for system user"):
client.succeed("${sendMail "system" "" accounts."normal".address ''
Subject: Testmail2
Hello User1,
this is some text!
''}")
# give the mail server some time to process the mail
server.wait_until_fails('${pendingPostqueue}')
with subtest("mail can be retrieved via imap"):
client.succeed("${recvMail "normal"} >&2")
with subtest("mail sent to system-account is rejected"):
client.fail("${sendMail "normal" "someotheraddress@example.com" accounts."system".address ''
Subject: Mail to system-account