Add --all option to crosstest

Uwe Bonnes bon at elektron.ikp.physik.tu-darmstadt.de
Sun Jul 3 11:52:35 CDT 2005


       Changelog
       wine/include/wine/test.h
       Add --all option to run all tests in the testlist
-- 
Uwe Bonnes                bon at elektron.ikp.physik.tu-darmstadt.de

Institut fuer Kernphysik  Schlossgartenstrasse 9  64289 Darmstadt
--------- Tel. 06151 162516 -------- Fax. 06151 164321 ----------
Index: wine/include/wine/test.h
===================================================================
RCS file: /home/wine/wine/include/wine/test.h,v
retrieving revision 1.20
diff -u -r1.20 test.h
--- wine/include/wine/test.h	30 Jun 2005 21:13:00 -0000	1.20
+++ wine/include/wine/test.h	3 Jul 2005 16:47:32 -0000
@@ -367,7 +367,7 @@
 /* Display usage and exit */
 static void usage( const char *argv0 )
 {
-    fprintf( stdout, "Usage: %s test_name\n\n", argv0 );
+    fprintf( stdout, "Usage: %s [test_name|--list|--all]\n\n", argv0 );
     list_tests();
     exit_process(1);
 }
@@ -397,6 +397,14 @@
     {
         list_tests();
         return 0;
+    }
+    if (!strcmp( argv[1], "--all" ))
+    {
+	const struct test *test;
+	int status =0;
+	for (test = winetest_testlist; test->name; test++)
+	    status += run_test(test->name);
+	return status;
     }
     return run_test(argv[1]);
 }



More information about the wine-patches mailing list