Skip to content

Commit 035059e

Browse files
committed
tests/run-multitests.py: Add TRACE banner and move TEST output to end.
To make it easier to understand the output when both -s and -t are used.
1 parent 67fca2b commit 035059e

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

tests/run-multitests.py

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -230,6 +230,9 @@ def run_test_on_instances(test_file, num_instances, instances):
230230
injected_globals = ""
231231
output = [[] for _ in range(num_instances)]
232232

233+
if cmd_args.trace_output:
234+
print("TRACE {}:".format("|".join(str(i) for i in instances)))
235+
233236
# Start all instances running, in order, waiting until they signal they are ready
234237
for idx in range(num_instances):
235238
append_code = APPEND_CODE_TEMPLATE.format(injected_globals, idx)
@@ -326,10 +329,6 @@ def run_tests(test_files, instances_truth, instances_test):
326329
# Run test on test instances
327330
error, skip, output_test = run_test_on_instances(test_file, num_instances, instances_test)
328331

329-
if cmd_args.show_output:
330-
print("### TEST ###")
331-
print(output_test, end="")
332-
333332
if not skip:
334333
# Check if truth exists in a file, and read it in
335334
test_file_expected = test_file + ".exp"
@@ -341,7 +340,11 @@ def run_tests(test_files, instances_truth, instances_test):
341340
_, _, output_truth = run_test_on_instances(
342341
test_file, num_instances, instances_truth
343342
)
344-
if cmd_args.show_output:
343+
344+
if cmd_args.show_output:
345+
print("### TEST ###")
346+
print(output_test, end="")
347+
if not skip:
345348
print("### TRUTH ###")
346349
print(output_truth, end="")
347350

0 commit comments

Comments
 (0)