]> xenbits.xensource.com Git - libvirt.git/commitdiff
tests: add some self-documentation to tests
authorAlon Levy <alevy@redhat.com>
Tue, 8 May 2012 17:46:45 +0000 (20:46 +0300)
committerEric Blake <eblake@redhat.com>
Tue, 8 May 2012 18:38:11 +0000 (12:38 -0600)
Alon tried './qemuxml2argvtest --help' to figure out a test failure,
but it didn't help.  The information is in HACKING, but it doesn't
hurt to make the tests also provide their own help.

Signed-off-by: Alon Levy <alevy@redhat.com>
Signed-off-by: Eric Blake <eblake@redhat.com>
tests/testutils.c

index 4e8484fb68c853e95eecf146d56d81789cc72007..6eb40ed6e2f318f8e459ca83046119b28a11adda 100644 (file)
@@ -577,6 +577,10 @@ int virtTestMain(int argc,
         progname += 2;
     if (argc > 1) {
         fprintf(stderr, "Usage: %s\n", argv[0]);
+        fputs("effective environment variables:\n"
+              "VIR_TEST_VERBOSE set to show names of individual tests\n"
+              "VIR_TEST_DEBUG set to show information for debugging failures\n",
+              stderr);
         return EXIT_FAILURE;
     }
     fprintf(stderr, "TEST: %s\n", progname);