Title: [95532] trunk/Tools
Revision
95532
Author
[email protected]
Date
2011-09-20 05:34:51 -0700 (Tue, 20 Sep 2011)

Log Message

WebKitTestRunner: Provide usage if run without arguments

If WTR is run without either one or more filenames, or
a '-' to indicate server mode, we don't need to start
up the test machinery. Doing so might actually crash,
as we'll exit the application immedeatly after anyways.

Reviewed by Simon Hausmann.

Modified Paths

Diff

Modified: trunk/Tools/ChangeLog (95531 => 95532)


--- trunk/Tools/ChangeLog	2011-09-20 12:25:54 UTC (rev 95531)
+++ trunk/Tools/ChangeLog	2011-09-20 12:34:51 UTC (rev 95532)
@@ -1,5 +1,19 @@
 2011-09-20  Tor Arne Vestbø  <[email protected]>
 
+        WebKitTestRunner: Provide usage if run without arguments
+
+        If WTR is run without either one or more filenames, or
+        a '-' to indicate server mode, we don't need to start
+        up the test machinery. Doing so might actually crash,
+        as we'll exit the application immedeatly after anyways.
+
+        Reviewed by Simon Hausmann.
+
+        * WebKitTestRunner/TestController.cpp:
+        (WTR::TestController::initialize):
+
+2011-09-20  Tor Arne Vestbø  <[email protected]>
+
         [Qt] Don't use QFont before initializing QApplication
 
         Could potentially result in crash.

Modified: trunk/Tools/WebKitTestRunner/TestController.cpp (95531 => 95532)


--- trunk/Tools/WebKitTestRunner/TestController.cpp	2011-09-20 12:25:54 UTC (rev 95531)
+++ trunk/Tools/WebKitTestRunner/TestController.cpp	2011-09-20 12:34:51 UTC (rev 95532)
@@ -211,6 +211,13 @@
 {
     platformInitialize();
 
+    if (argc < 2) {
+        fputs("Usage: WebKitTestRunner [options] filename [filename2..n]\n", stderr);
+        // FIXME: Refactor option parsing to allow us to print
+        // an auto-generated list of options.
+        exit(1);
+    }
+
     bool printSupportedFeatures = false;
 
     for (int i = 1; i < argc; ++i) {
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to