Skip to content

Commit

Permalink
Write an outcome file line for every component
Browse files Browse the repository at this point in the history
This should make failures.csv on the CI be a complete list of failures
(although it will still have incomplete information on what has failed, if
what failed wasn't tracked individually).

Signed-off-by: Gilles Peskine <[email protected]>
  • Loading branch information
gilles-peskine-arm committed Oct 30, 2024
1 parent ee676d2 commit 13d5b99
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions tests/scripts/all-core.sh
Original file line number Diff line number Diff line change
Expand Up @@ -790,6 +790,19 @@ pre_prepare_outcome_file () {
fi
}
## write_outcome_line SUITE CASE RESULT [CAUSE]
## Write a line in the outcome file if enabled.
## Report $MBEDTLS_TEST_PLATFORM, $MBEDTLS_TEST_CONFIGURATION and the
## supplied arguments.
write_outcome_line () {
if [ -z "$MBEDTLS_TEST_OUTCOME_FILE" ]; then
return
fi
printf '%s;%s;%s;%s;%s;%s\n' >>"$MBEDTLS_TEST_OUTCOME_FILE" \
"$MBEDTLS_TEST_PLATFORM" "$MBEDTLS_TEST_CONFIGURATION" \
"$1" "$2" "$3" "${4-}"
}
pre_print_configuration () {
if [ $QUIET -eq 1 ]; then
return
Expand Down Expand Up @@ -983,6 +996,12 @@ run_component () {
fi
fi
if [ $component_status -eq 0 ]; then
write_outcome_line "all.sh" "whole" "PASS"
else
write_outcome_line "all.sh" "whole" "FAIL" "$component_status"
fi
# Restore the build tree to a clean state.
cleanup
unset current_component
Expand Down

0 comments on commit 13d5b99

Please sign in to comment.