mirror of
https://github.com/docker-mailserver/docker-mailserver.git
synced 2024-01-19 02:48:50 +00:00
Improvements on CI tests: now user account checks are working.
Need to work on fail2ban tests.
This commit is contained in:
parent
b35c79a8dd
commit
a6d666b450
|
@ -52,7 +52,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
@test "checking imap: server is ready with STARTTLS" {
|
@test "checking imap: server is ready with STARTTLS" {
|
||||||
run docker exec mail /bin/bash -c "nc -w 1 0.0.0.0 143 | grep '* OK' | grep 'STARTTLS' | grep 'ready'"
|
run docker exec mail /bin/bash -c "nc -w 5 0.0.0.0 143 | grep '* OK' | grep 'STARTTLS' | grep 'ready'"
|
||||||
[ "$status" -eq 0 ]
|
[ "$status" -eq 0 ]
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -182,32 +182,15 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
@test "checking accounts: user mail folders for user1" {
|
@test "checking accounts: user mail folders for user1" {
|
||||||
run docker exec mail ls -A /var/mail/localhost.localdomain/user1
|
run docker exec mail /bin/bash -c "ls -A /var/mail/localhost.localdomain/user1 | grep -E '.Drafts|.Sent|.Trash|cur|new|subscriptions|tmp' | wc -l"
|
||||||
[ "$status" -eq 0 ]
|
[ "$status" -eq 0 ]
|
||||||
[ "${lines[0]}" = ".Drafts" ]
|
[ "$output" -eq 7 ]
|
||||||
[ "${lines[1]}" = ".Sent" ]
|
|
||||||
[ "${lines[2]}" = ".Trash" ]
|
|
||||||
[ "${lines[3]}" = "cur" ]
|
|
||||||
[ "${lines[4]}" = "dovecot-uidlist" ]
|
|
||||||
[ "${lines[5]}" = "dovecot-uidvalidity" ]
|
|
||||||
[ "${lines[6]}" = "dovecot-uidvalidity.5712dae3" ]
|
|
||||||
[ "${lines[7]}" = "dovecot.index.cache" ]
|
|
||||||
[ "${lines[8]}" = "dovecot.index.log" ]
|
|
||||||
[ "${lines[9]}" = "new" ]
|
|
||||||
[ "${lines[10]}" = "subscriptions" ]
|
|
||||||
[ "${lines[11]}" = "tmp" ]
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@test "checking accounts: user mail folders for user2" {
|
@test "checking accounts: user mail folders for user2" {
|
||||||
run docker exec mail ls -A /var/mail/otherdomain.tld/user2
|
run docker exec mail /bin/bash -c "ls -A /var/mail/otherdomain.tld/user2 | grep -E '.Drafts|.Sent|.Trash|cur|new|subscriptions|tmp' | wc -l"
|
||||||
[ "$status" -eq 0 ]
|
[ "$status" -eq 0 ]
|
||||||
[ "${lines[0]}" = ".Drafts" ]
|
[ "$output" -eq 7 ]
|
||||||
[ "${lines[1]}" = ".Sent" ]
|
|
||||||
[ "${lines[2]}" = ".Trash" ]
|
|
||||||
[ "${lines[3]}" = "cur" ]
|
|
||||||
[ "${lines[4]}" = "new" ]
|
|
||||||
[ "${lines[5]}" = "subscriptions" ]
|
|
||||||
[ "${lines[6]}" = "tmp" ]
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#
|
#
|
||||||
|
|
Loading…
Reference in a new issue