Add end-to-end Test
- Add an infrastructur to run local e2e tests. - Add some tests.
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
#!/usr/bin/bash
|
||||
|
||||
echo "Basic: Test if MTA is working"
|
||||
|
||||
adduser --shell /bin/bash --disabled-password --gecos "" mtatest
|
||||
echo "test mail" | sendmail mtatest@example.com
|
||||
|
||||
sleep 1
|
||||
|
||||
if [ -f /var/mail/mtatest ] ; then
|
||||
RESULT_CODE=0
|
||||
else
|
||||
RESULT_CODE=1
|
||||
fi
|
||||
|
||||
deluser --remove-home mtatest
|
||||
|
||||
exit $RESULT_CODE
|
||||
Reference in New Issue
Block a user