From c021e2f9eb3d06d3379eb2d3d0a5479c0ebdc73e Mon Sep 17 00:00:00 2001 From: Pekka Paalanen Date: Fri, 18 Jun 2021 10:33:29 +0300 Subject: [PATCH] tests: reduce subsurface-test verbosity Not printing these will drop 7980 lines or roughly 350 kB from the test logs. Now I don't have scroll through them all, and I don't have to watch them if I run this test manually. These prints were useful when developing the test, but we don't need them printed in CI all the time. Printing the final count should be enough. Signed-off-by: Pekka Paalanen --- tests/subsurface-test.c | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/tests/subsurface-test.c b/tests/subsurface-test.c index 2581b09f..53f8f227 100644 --- a/tests/subsurface-test.c +++ b/tests/subsurface-test.c @@ -31,6 +31,8 @@ #include "weston-test-client-helper.h" #include "weston-test-fixture-compositor.h" +#define VERBOSE 0 + static enum test_result_code fixture_setup(struct weston_test_harness *harness) { @@ -841,11 +843,13 @@ destroy_permu_object(struct wl_surface **surfs, int h = (i + 1) / 2; if (i & 1) { - testlog(" [sub %2d]", h); + if (VERBOSE) + testlog(" [sub %2d]", h); wl_subsurface_destroy(subs[h]); subs[h] = NULL; } else { - testlog(" [surf %2d]", h); + if (VERBOSE) + testlog(" [surf %2d]", h); wl_surface_destroy(surfs[h]); surfs[h] = NULL; } @@ -883,15 +887,18 @@ TEST(test_subsurface_destroy_permutations) create_subsurface_tree(client, surfs, subs, test_size); - testlog("permu"); + if (VERBOSE) + testlog("permu"); - for (i = 0; i < NSTEPS; i++) - testlog(" %2d", per.cnt[i]); + if (VERBOSE) + for (i = 0; i < NSTEPS; i++) + testlog(" %2d", per.cnt[i]); for (i = 0; i < NSTEPS; i++) destroy_permu_object(surfs, subs, per.cnt[i]); - testlog("\n"); + if (VERBOSE) + testlog("\n"); client_roundtrip(client); destroy_subsurface_tree(surfs, subs, test_size);