Skip to content

Commit fd0ba7b

Browse files
dlechdpgeorge
authored andcommitted
tools/tinytest-codegen.py: Add extra newline and result message.
This is an alternative to f4ed2df that adds a newline so that the output of the test starts on a new line and the result of the test is prefixed with "result: " to distinguish it from the test output. Suggested-by: @dpgeorge
1 parent 1605c7e commit fd0ba7b

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

tools/tinytest-codegen.py

+2
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,10 @@ def script_to_map(test_file):
3333
"void {name}(void* data) {{\n"
3434
" static const char pystr[] = {script};\n"
3535
" static const char exp[] = {output};\n"
36+
' printf("\\n");\n'
3637
" upytest_set_expected_output(exp, sizeof(exp) - 1);\n"
3738
" upytest_execute_test(pystr);\n"
39+
' printf("result: ");\n'
3840
"}}"
3941
)
4042

0 commit comments

Comments
 (0)