gtestutils: Use TAP format for all the verbose output

In some cases if verbose output was enabled we were using wrong output
format in TAP mode, so let's fix these cases and run the 'testing' test
case in --verbose mode to ensure we won't regress.
This commit is contained in:
Marco Trevisan (Treviño) 2023-01-13 18:51:47 +01:00
parent 5c799ff01d
commit a943d42104
2 changed files with 14 additions and 2 deletions

View File

@ -3023,7 +3023,12 @@ test_should_run (const char *test_path,
return TRUE;
if (g_test_verbose ())
g_print ("GTest: skipping: %s\n", test_run_name);
{
if (test_tap_log)
g_print ("# skipping: %s\n", test_run_name);
else
g_print ("GTest: skipping: %s\n", test_run_name);
}
return FALSE;
}
@ -3867,7 +3872,12 @@ g_test_trap_subprocess (const char *test_path,
}
if (g_test_verbose ())
g_print ("GTest: subprocess: %s\n", test_path);
{
if (test_tap_log)
g_print ("# subprocess: %s\n", test_path);
else
g_print ("GTest: subprocess: %s\n", test_path);
}
test_trap_clear ();
test_trap_last_subprocess = g_strdup (test_path);

View File

@ -140,6 +140,7 @@ glib_tests = {
'string' : {},
'strvbuilder' : {},
'testing' : {
'args': [ '--verbose' ],
'extra_programs' : ['testing-helper'],
},
'test-printf' : {},
@ -398,6 +399,7 @@ foreach test_name, extra_args : glib_tests
endforeach
test(test_name, exe,
args: extra_args.get('args', []),
protocol : extra_args.get('protocol', test_protocol),
depends : depends,
env : test_env,