From b621b769ca742d65062700b8db89533fb9dc8105 Mon Sep 17 00:00:00 2001 From: Nikolay Stanchev <ns17@it-innovation.soton.ac.uk> Date: Sun, 3 Jun 2018 10:56:48 +0100 Subject: [PATCH] Added tox execution in the service install script - seems that tox is running fine within lxc containers --- scripts/clmc-service/install.sh | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/scripts/clmc-service/install.sh b/scripts/clmc-service/install.sh index 8403923..4928337 100755 --- a/scripts/clmc-service/install.sh +++ b/scripts/clmc-service/install.sh @@ -139,6 +139,16 @@ if [ $? -ne 0 ] ; then exit 1 fi +# running tests using tox +echo "----> Running tox" +TOX_OUTPUT="$(tox)" +# check if tox output contains the 'congratulations :)' bit for tests passed +if [[ $TOX_OUTPUT != *"congratulations :)"* ]]; then + echo "CLMC service unit tests failed." + exit 1 +fi +echo "----> Tox execution of unit tests passed successfully" + # install the service echo "----> Installing CLMC web service" pip3 install . -- GitLab