sort the complement results by test name for consistent output

Signed-off-by: strawberry <strawberry@puppygock.gay>
This commit is contained in:
strawberry 2024-05-02 10:32:30 -04:00 committed by June
parent e1052d1829
commit 35683d66dd
2 changed files with 77 additions and 77 deletions

View file

@ -37,10 +37,10 @@ env \
go test -vet=off -timeout 1h -json ./tests | tee "$LOG_FILE"
set -o pipefail
# Post-process the results into an easy-to-compare format
cat "$LOG_FILE" | jq -c '
# Post-process the results into an easy-to-compare format, sorted by Test name for reproducible results
cat "$LOG_FILE" | jq -s -c 'sort_by(.Test)[]' | jq -c '
select(
(.Action == "pass" or .Action == "fail" or .Action == "skip")
and .Test != null
) | {Action: .Action, Test: .Test}
' | sort > "$RESULTS_FILE"
' > "$RESULTS_FILE"