Skip to content

Commit

Permalink
Run in parallel as well
Browse files Browse the repository at this point in the history
  • Loading branch information
aelovikov-intel committed Apr 23, 2024
1 parent 6685358 commit 2ef17a6
Showing 1 changed file with 13 additions and 11 deletions.
24 changes: 13 additions & 11 deletions .github/workflows/sycl-linux-run-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -336,19 +336,21 @@ jobs:
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#custom-shell
shell: bash {0}
run: |
failed_suites=""
# Run each test category separately so that
# - crash on one would not affect others
# - multiple tests could be run in parallel
# test_all contains all categories, so skip it
mkdir logs
find build-cts/bin/ ! -name 'test_all' -print | \
xargs -t -I % -P 8 sh -c 'log=logs/$(basename %).log ; echo % >$log ; /usr/bin/time -p timeout 10s % >>$log 2>&1 ; ret=$? ; echo "exit code: $ret" >>$log ; exit $ret'
ret=$?
for i in `ls -1 ./build-cts/bin`; do
echo "::group::Running $i"
build-cts/bin/$i
[ $? -ne 0 ] && failed_suites+=$i'\n'
for f in logs/* ; do
echo "::group::$f"
cat $f
echo "::endgroup::"
done
if [ -n "$failed_suites" ]; then
echo -e "Failed suite(s): $failed_suites"
echo -e "Failed suite(s): $failed_suites" >> $GITHUB_STEP_SUMMARY
exit 1
fi
grep 'exit code: [^0]' -r logs >> $GITHUB_STEP_SUMMARY
exit 0
exit $ret

0 comments on commit 2ef17a6

Please sign in to comment.