Skip to content

Commit

Permalink
Print results of check_outputs
Browse files Browse the repository at this point in the history
  • Loading branch information
dfornika committed Jun 12, 2024
1 parent e23c53e commit a409404
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions .github/scripts/check_outputs.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
import glob
import json
import os
import sys
import urllib.request

from jsonschema import validate
Expand Down Expand Up @@ -94,14 +95,17 @@ def main(args):

output_path = args.output
with open(output_path, 'w') as f:
writer = csv.DictWriter(f, fieldnames=output_fields, extrasaction='ignore')
writer.writeheader()
file_writer = csv.DictWriter(f, fieldnames=output_fields, extrasaction='ignore')
stdout_writer = csv.DictWriter(sys.stdout, fieldnames=output_fields, extrasaction='ignore')
stdout_writer.writeheader()
file_writer.writeheader()
for test in tests:
if test["test_passed"]:
test["test_result"] = "PASS"
else:
test["test_result"] = "FAIL"
writer.writerow(test)
stdout_writer.writerow(test)
file_writer.writerow(test)

for test in tests:
if not test['test_passed']:
Expand Down

0 comments on commit a409404

Please sign in to comment.