Skip to content

Commit eac3e15

Browse files
committed
Improved parsing of tests
1 parent 4ca126c commit eac3e15

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

.github/workflows/integration-test.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -266,9 +266,8 @@ jobs:
266266
run: |
267267
echo "Failed Tests in ${{ matrix.integration.name }}"
268268
if [[ -f test_output.log ]]; then
269-
# Count only test failure lines and avoid duplicate "0" outputs
270-
failed_count=$(grep -E '^--- FAIL:' test_output.log | wc -l | tr -d '[:space:]')
271-
failed_count=${failed_count:-0}
269+
# Count only test failure lines in a way that is safe with -e -o pipefail
270+
failed_count=$(grep -E -c '^--- FAIL:' test_output.log || echo 0)
272271
echo "Failed tests count: $failed_count"
273272
if [[ "${failed_count}" -gt 0 ]]; then
274273
echo "Failed test names:"

0 commit comments

Comments
 (0)