You've already forked docker-mailserver
mirror of
https://github.com/docker-mailserver/docker-mailserver.git
synced 2025-08-07 23:03:10 +02:00
tests: improve _send_email
(#3105)
This commit is contained in:
@ -21,8 +21,7 @@ function setup_file() {
|
||||
function teardown_file() { _default_teardown ; }
|
||||
|
||||
@test '(Dovecot) LDAP RIMAP connection and authentication works' {
|
||||
_run_in_container_bash "nc -w 1 0.0.0.0 143 < /tmp/docker-mailserver-test/auth/imap-auth.txt"
|
||||
assert_success
|
||||
_send_email 'auth/imap-auth' '-w 1 0.0.0.0 143'
|
||||
}
|
||||
|
||||
@test '(SASLauthd) SASL RIMAP authentication works' {
|
||||
@ -31,14 +30,13 @@ function teardown_file() { _default_teardown ; }
|
||||
}
|
||||
|
||||
@test '(SASLauthd) RIMAP SMTP authentication works' {
|
||||
_run_in_container_bash 'nc -w 5 0.0.0.0 25 < /tmp/docker-mailserver-test/auth/smtp-auth-login.txt'
|
||||
assert_success
|
||||
_send_email 'auth/smtp-auth-login' '-w 5 0.0.0.0 25'
|
||||
assert_output --partial 'Error: authentication not enabled'
|
||||
_run_in_container_bash 'nc -w 5 0.0.0.0 465 < /tmp/docker-mailserver-test/auth/smtp-auth-login.txt'
|
||||
assert_success
|
||||
|
||||
_send_email 'auth/smtp-auth-login' '-w 5 0.0.0.0 465'
|
||||
assert_output --partial 'Authentication successful'
|
||||
_run_in_container_bash 'nc -w 5 0.0.0.0 587 < /tmp/docker-mailserver-test/auth/smtp-auth-login.txt'
|
||||
assert_success
|
||||
|
||||
_send_email 'auth/smtp-auth-login' '-w 5 0.0.0.0 587'
|
||||
assert_output --partial 'Authentication successful'
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user