Skip to content

Commit 2d5b776

Browse files
authored
Update classroom.yml
1 parent 70f0099 commit 2d5b776

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

.github/workflows/classroom.yml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,17 @@ jobs:
2525
- name: Run autograder
2626
id: grading
2727
uses: education/autograding@v1
28-
28+
- name: Fail if critical tests failed
29+
run: |
30+
RESULTS=".autograding/results.json"
31+
if jq -e '.tests[] | select(.name == "Compilation Check" and .status != "passed")' "$RESULTS"; then
32+
echo "❌ Compilation failed"
33+
exit 1
34+
fi
35+
if jq -e '.tests[] | select(.name == "Basic Tests" and .status != "passed")' "$RESULTS"; then
36+
echo "❌ Basic tests failed"
37+
exit 1
38+
fi
2939
ai_feedback:
3040
name: AI-Powered Feedback
3141
needs: autograding

0 commit comments

Comments
 (0)