Improve 'make clean' (#323)

Remove also all temporary test files. A new test can be started without
reclone the repository.
This commit is contained in:
Josef Friedrich 2016-09-12 17:49:46 +02:00 committed by Thomas VIAL
parent 535f809c5b
commit f42a0c1935
1 changed files with 19 additions and 1 deletions

View File

@ -80,6 +80,7 @@ run:
sleep 20
fixtures:
cp config/postfix-accounts.cf config/postfix-accounts.cf.bak
# Setup sieve & create filtering folder (INBOX/spam)
docker cp "`pwd`/test/config/sieve/dovecot.sieve" mail:/var/mail/localhost.localdomain/user1/.dovecot.sieve
docker exec mail /bin/sh -c "maildirmake.dovecot /var/mail/localhost.localdomain/user1/.INBOX.spam"
@ -105,4 +106,21 @@ tests:
clean:
# Remove running test containers
docker rm -f mail mail_pop3 mail_smtponly mail_fail2ban mail_fetchmail fail-auth-mailer mail_disabled_amavis mail_disabled_clamav mail_manual_ssl
-docker rm -f \
mail \
mail_pop3 \
mail_smtponly \
mail_fail2ban \
mail_fetchmail \
fail-auth-mailer \
mail_disabled_amavis \
mail_disabled_clamav \
mail_manual_ssl
@if [ -f config/postfix-accounts.cf.bak ]; then\
rm -f config/postfix-accounts.cf ;\
mv config/postfix-accounts.cf.bak config/postfix-accounts.cf ;\
fi
-rm -rf test/onedir \
test/config/empty \
test/config/without-accounts \
test/config/without-virtual