-
-
Notifications
You must be signed in to change notification settings - Fork 172
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Resolves #658
- Loading branch information
Showing
4 changed files
with
41 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,18 @@ | ||
#!/bin/bash | ||
set -o nounset -o errexit -o pipefail | ||
|
||
cleanup() { | ||
echo "Stopping and removing smtpdev ..." | ||
docker stop smtp4dev_wakapi &> /dev/null || true | ||
docker rm -f smtp4dev_wakapi &> /dev/null | ||
} | ||
trap cleanup EXIT | ||
|
||
cleanup | ||
|
||
echo "Starting smtp4dev in Docker ..." | ||
docker run -d --rm -p 2525:25 -p 8080:80 --name smtp4dev_wakapi rnwood/smtp4dev | ||
|
||
echo "Running tests ..." | ||
go test -run TestSmtpTestSuite ../services/mail | ||
|
||
echo "Killing container again ..." | ||
docker stop smtp4dev_wakapi | ||
script_dir=$(dirname "${BASH_SOURCE[0]}") | ||
go test -count=1 -run TestSmtpTestSuite "$script_dir/../services/mail" |