Skip to content

Commit

Permalink
Improve wording, but still fail
Browse files Browse the repository at this point in the history
  • Loading branch information
SketchingDev committed Jul 20, 2023
1 parent 11c23ea commit 1a7b603
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions examples/cli/run.sh
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
#sh

RED='\033[0;31m'
NO_COLOUR='\033[0m'

npm install -g ../../packages/genesys-web-messaging-tester-cli

function cleanup {
Expand All @@ -14,15 +11,17 @@ trap cleanup EXIT
web-messaging-tester example-pass.yml -id $DEPLOYMENT_ID -r $REGION -p 10
if [ $? -ne 0 ]
then
echo "\n\n${RED}Passing test did not result in Exit Code of 0. Exit code was $?${NO_COLOUR}"
echo "========="
echo "UNEXPECTED EXIT CODE $? - Failing test did not result in Exit Code of 0"
exit 1
fi

## Failing test exists with code 1
web-messaging-tester example-fail.yml -id $DEPLOYMENT_ID -r $REGION -p 10
if [ $? -ne 0 ]
then
echo "\n\n${RED}Failing test did not result in Exit Code of 1. Exit code was $?${NO_COLOUR}"
echo "========="
echo "UNEXPECTED EXIT CODE $? - Failing test did not result in Exit Code of 1"
exit 1
fi

Expand Down

0 comments on commit 1a7b603

Please sign in to comment.