Skip to content

Commit

Permalink
Print status message based on number of tests run (#211)
Browse files Browse the repository at this point in the history
  • Loading branch information
nitisht committed Nov 6, 2017
1 parent 7e9333c commit 88b0040
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions mint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -122,21 +122,27 @@ function main()
fi

count="${#run_list[@]}"
i=1
i=0
for sdk_dir in "${run_list[@]}"; do
sdk_name=$(basename "$sdk_dir")
(( i++ ))
if [ ! -d "$sdk_dir" ]; then
echo "Test $sdk_name not found. Exiting Mint."
exit 1
fi
echo -n "($i/$count) Running $sdk_name tests ... "
if ! run_test "$sdk_dir"; then
(( i-- ))
break
fi
(( i++ ))
done

echo "Finished running all tests."
## Report when all tests in run_list are run
if [ $i -eq "$count" ]; then
echo -e "\nAll tests ran successfully"
else
echo -e "\nExecuted $i out of $count tests successfully."
fi
}

main "$@"

0 comments on commit 88b0040

Please sign in to comment.