Skip to content

Commit

Permalink
CI add passing/failing criteria
Browse files Browse the repository at this point in the history
  • Loading branch information
M0stafaRady committed Feb 20, 2024
1 parent 805e1da commit 1e121e7
Showing 1 changed file with 15 additions and 5 deletions.
20 changes: 15 additions & 5 deletions .github/workflows/uvm_ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,21 @@ jobs:
- name: Clean passed runs
run: make clean_passed_dirs

- name: Check for directories under sim
- name: Check for test results in sim/default_run
run: |
if [ "$(ls -A sim/)" ]; then
echo "Error: runs exist under sim after cleanup"
exit 1
cd verify/uvm-python
passed_count=$(find sim/default_run -type f -name 'passed' | wc -l)
failed_count=$(find sim/default_run -type f -name 'failed' | wc -l)
unknown_count=$(find sim/default_run -type f -name 'unknown' | wc -l)
echo "Passed: $passed_count"
echo "Failed: $failed_count"
echo "Unknown: $unknown_count"
if [ "$failed_count" -ne 0 ] || [ "$unknown_count" -ne 0 ]; then
echo "Error: There are failed or unknown test results"
exit 1
else
echo "Cleanup successful, no directories under sim"
echo "All tests passed successfully"
fi

0 comments on commit 1e121e7

Please sign in to comment.