diff options
author | Werner Koch <wk@gnupg.org> | 2016-05-03 11:26:06 +0200 |
---|---|---|
committer | Werner Koch <wk@gnupg.org> | 2016-05-03 11:26:06 +0200 |
commit | 33aacc3d4bbd6a82d7e7ceca058970879741b7da (patch) | |
tree | 87d74f35156740dc845f8a5d6bfbd610f490fbf7 /g10/test.c | |
parent | gpg: Emit status lines TOFU_STATS and TOFU_STATS_LONG. (diff) | |
download | gnupg2-33aacc3d4bbd6a82d7e7ceca058970879741b7da.tar.xz gnupg2-33aacc3d4bbd6a82d7e7ceca058970879741b7da.zip |
tests: Silence output of some tests.
* common/t-exechelp.c (print_open_fds): Silence non-verbose output.
(test_close_all_fds): Ditto.
* common/t-session-env.c (show_stdnames): Indent output.
* g10/test.c (TEST): Silence non-verbose okay output.
(exit_tests): Ditto.
* tools/gpg-zip.in (tar_verbose_opt): Add option --quiet.
* tests/openpgp/gpgtar.test (GPGZIP): Pass option --quiet.
* tests/openpgp/mds.test: Indent MD5 notice.
* tests/openpgp/version.test: Indent --version output.
Signed-off-by: Werner Koch <wk@gnupg.org>
Diffstat (limited to 'g10/test.c')
-rw-r--r-- | g10/test.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/g10/test.c b/g10/test.c index 39d594594..e9e2074d3 100644 --- a/g10/test.c +++ b/g10/test.c @@ -74,10 +74,13 @@ static int verbose; \ if (test_result == expected_result) \ { \ - printf (" ok.\n"); \ + if (verbose) printf (" ok.\n"); \ } \ else \ { \ + if (!verbose) \ + printf ("%d. Checking %s...", \ + tests, (description) ?: ""); \ printf (" failed.\n"); \ printf (" %s == %s failed.\n", \ STRINGIFY(test), \ @@ -125,7 +128,8 @@ exit_tests (int force) { if (tests_failed == 0) { - printf ("All %d tests passed.\n", tests); + if (verbose) + printf ("All %d tests passed.\n", tests); exit (!!force); } else |