1
0
mirror of https://blitiri.com.ar/repos/chasquid synced 2025-12-17 14:37:02 +00:00

smtpsrv: Disable reloads during tests

Reloading during tests will cause the testing aliases to be removed,
which makes test runs that extend beyond 30s to be flaky.

This patch fixes the bug by disabling reloads during these tests.
This commit is contained in:
Alberto Bertogli
2019-12-01 18:48:08 +00:00
parent e8a6bf6188
commit 99c4ad5ef7
2 changed files with 6 additions and 0 deletions

View File

@@ -584,6 +584,9 @@ func realMain(m *testing.M) int {
// Disable SPF lookups, to avoid leaking DNS queries.
disableSPFForTesting = true
// Disable reloading.
reloadEvery = nil
go s.ListenAndServe()
}