mirror of
https://blitiri.com.ar/repos/chasquid
synced 2025-12-17 14:37:02 +00:00
smtpsrv: Make tests log maillog to stdout
This commit is contained in:
@@ -18,6 +18,7 @@ import (
|
||||
"time"
|
||||
|
||||
"blitiri.com.ar/go/chasquid/internal/aliases"
|
||||
"blitiri.com.ar/go/chasquid/internal/maillog"
|
||||
"blitiri.com.ar/go/chasquid/internal/testlib"
|
||||
"blitiri.com.ar/go/chasquid/internal/userdb"
|
||||
)
|
||||
@@ -532,6 +533,10 @@ func realMain(m *testing.M) int {
|
||||
}
|
||||
str1MiB = string(buf)
|
||||
|
||||
// Set up the mail log to stdout, which is captured by the test runner,
|
||||
// so we have better debugging information on failures.
|
||||
maillog.Default = maillog.New(os.Stdout)
|
||||
|
||||
if *externalSMTPAddr != "" {
|
||||
smtpAddr = *externalSMTPAddr
|
||||
submissionAddr = *externalSubmissionAddr
|
||||
|
||||
Reference in New Issue
Block a user