Re: [PATCH v3 05/11] tests/qtest/qos-test: dump environment variables if verbose

2020-10-08 Thread Christian Schoenebeck
On Donnerstag, 8. Oktober 2020 15:52:08 CEST Paolo Bonzini wrote: > On 08/10/20 15:42, Christian Schoenebeck wrote: > >> I'm okay I guess with using g_test_message on 2.62 or newer, and > >> assuming people don't use --tap --verbose on older versions. > > > > Simpler solution: just appending '#' c

Re: [PATCH v3 05/11] tests/qtest/qos-test: dump environment variables if verbose

2020-10-08 Thread Paolo Bonzini
On 08/10/20 15:42, Christian Schoenebeck wrote: >> >> I'm okay I guess with using g_test_message on 2.62 or newer, and >> assuming people don't use --tap --verbose on older versions. > Simpler solution: just appending '#' character in front of each printf() > line, > that would be both fine for T

Re: [PATCH v3 05/11] tests/qtest/qos-test: dump environment variables if verbose

2020-10-08 Thread Christian Schoenebeck
On Donnerstag, 8. Oktober 2020 15:21:54 CEST Paolo Bonzini wrote: > On 08/10/20 15:09, Christian Schoenebeck wrote: > >> But doesn't this (and patch 6 as well) break TAP output? Using > >> g_test_message + g_test_verbose would be the best of both worlds. > > > > If there was TAP output then yes,

Re: [PATCH v3 05/11] tests/qtest/qos-test: dump environment variables if verbose

2020-10-08 Thread Paolo Bonzini
On 08/10/20 15:09, Christian Schoenebeck wrote: >> But doesn't this (and patch 6 as well) break TAP output? Using >> g_test_message + g_test_verbose would be the best of both worlds. > > If there was TAP output then yes, patches 4, 5, 6 would probably break it. > > How/when is TAP output enabled

Re: [PATCH v3 05/11] tests/qtest/qos-test: dump environment variables if verbose

2020-10-08 Thread Christian Schoenebeck
On Donnerstag, 8. Oktober 2020 14:37:00 CEST Paolo Bonzini wrote: > On 02/10/20 18:15, Christian Schoenebeck wrote: > > -int main(int argc, char **argv) > > +int main(int argc, char **argv, char** envp) > > > > { > > > > g_test_init(&argc, &argv, NULL); > > > > +if (g_test_verbose())

Re: [PATCH v3 05/11] tests/qtest/qos-test: dump environment variables if verbose

2020-10-08 Thread Paolo Bonzini
On 02/10/20 18:15, Christian Schoenebeck wrote: > -int main(int argc, char **argv) > +int main(int argc, char **argv, char** envp) > { > g_test_init(&argc, &argv, NULL); > +if (g_test_verbose()) { > +printf("ENVIRONMENT VARIABLES: {\n"); > +for (char **env = envp; *env !=

[PATCH v3 05/11] tests/qtest/qos-test: dump environment variables if verbose

2020-10-02 Thread Christian Schoenebeck
If qtests are run in verbose mode (i.e. if --verbose CL argument was provided) then print all environment variables to stdout before running the individual tests. Instead of using g_test_message() rather use printf() in combination with g_test_verbose(), to avoid g_test_message() cluttering the ou