tests/ldap: fail fast if openldap schema is broken

This helps so much during development as it tells me openldap failed and
doesn't require me to do a root cause analysis on a postmap failure much
later in during the test.
This commit is contained in:
Martin Weinelt
2026-03-08 03:58:05 +01:00
parent 05968d7978
commit fa0d5c9694
+3
View File
@@ -131,6 +131,9 @@ in
machine.start() machine.start()
machine.wait_for_unit("multi-user.target") machine.wait_for_unit("multi-user.target")
# if the schema is broken, fail fast. helps during development.
machine.wait_for_unit("openldap.service")
# TODO put this blocking into the systemd units? # TODO put this blocking into the systemd units?
machine.wait_until_succeeds( machine.wait_until_succeeds(
"set +e; timeout 1 nc -U /run/rspamd/rspamd-milter.sock < /dev/null; [ $? -eq 124 ]" "set +e; timeout 1 nc -U /run/rspamd/rspamd-milter.sock < /dev/null; [ $? -eq 124 ]"