Skip to content

Commit

Permalink
Working on fixing CI for windows.
Browse files Browse the repository at this point in the history
  • Loading branch information
eriq-augustine committed Sep 26, 2023
1 parent 4e2b5c2 commit 771c991
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 13 deletions.
32 changes: 20 additions & 12 deletions .ci/run.sh
Original file line number Diff line number Diff line change
@@ -1,20 +1,28 @@
#!/bin/bash

readonly THIS_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
readonly BASE_DIR="${THIS_DIR}/.."

trap exit SIGINT
function main() {
if [[ $# -ne 0 ]]; then
echo "USAGE: $0"
exit 1
fi

exitStatus=0
trap exit SIGINT

# Run tests.
echo "Running tests ..."
local error_count=0

"${THIS_DIR}/../run_tests.py"
if [[ $? -eq 0 ]]; then
echo "Tests passed!"
else
echo "Tests failed. :("
exitStatus=1
fi
python3 "${BASE_DIR}/run_tests.py"
((error_count += $?))

exit ${exitStatus}
if [[ ${error_count} -gt 0 ]] ; then
echo "Found ${error_count} issues."
else
echo "No issues found."
fi

return ${error_count}
}

[[ "${BASH_SOURCE[0]}" == "${0}" ]] && main "$@"
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,4 +43,4 @@ jobs:
- name: Run Tests
shell: bash
run: ./run_tests.py
run: ./.ci/run.sh

0 comments on commit 771c991

Please sign in to comment.