tests: wait for rspamd-milter.sock in ldap and internal tests

I've hit more races in these tests recently while running the test suite
on a much faster host system.
This commit is contained in:
Martin Weinelt
2026-03-04 16:02:47 +01:00
parent ff91d3cf68
commit e1afec5b08
2 changed files with 10 additions and 0 deletions
+5
View File
@@ -115,6 +115,11 @@ in
machine.wait_for_unit("multi-user.target")
machine.wait_for_unit("dovecot.service")
# TODO put this blocking into the systemd units?
machine.wait_until_succeeds(
"set +e; timeout 1 nc -U /run/rspamd/rspamd-milter.sock < /dev/null; [ $? -eq 124 ]"
)
# Regression test for https://gitlab.com/simple-nixos-mailserver/nixos-mailserver/-/issues/205
with subtest("mail forwarded can are locally kept"):
# A mail sent to user2@example.com via explicit TLS is in the user1@example.com mailbox
+5
View File
@@ -128,6 +128,11 @@ in
machine.start()
machine.wait_for_unit("multi-user.target")
# TODO put this blocking into the systemd units?
machine.wait_until_succeeds(
"set +e; timeout 1 nc -U /run/rspamd/rspamd-milter.sock < /dev/null; [ $? -eq 124 ]"
)
# This function retrieves the ldap table file from a postconf
# command.
# A key lookup is achived and the returned value is compared