]> git.saurik.com Git - wxWidgets.git/commitdiff
disable FTPTestCase by default.
authorFrancesco Montorsi <f18m_cpp217828@yahoo.it>
Wed, 2 Jun 2010 10:49:44 +0000 (10:49 +0000)
committerFrancesco Montorsi <f18m_cpp217828@yahoo.it>
Wed, 2 Jun 2010 10:49:44 +0000 (10:49 +0000)
Add a warning for the user when running --list without arguments: not all tests are listed, only those enabled by default (e.g. FTPTestCase doesn't appear there)!

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64460 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

tests/test.cpp
tests/uris/ftp.cpp

index 676e33b35118cec65484eac0968506af130d4689..5e05c09423ef2268c7823d8e6628bb30cca2c605 100644 (file)
@@ -441,7 +441,7 @@ void TestApp::OnInitCmdLine(wxCmdLineParser& parser)
             "print the test case names, run them",
             wxCMD_LINE_VAL_NONE, 0 },
         { wxCMD_LINE_SWITCH, "t", "timing",
-            "print names and mesure running time of individual test, run them",
+            "print names and measure running time of individual test, run them",
             wxCMD_LINE_VAL_NONE, 0 },
         { wxCMD_LINE_OPTION, "", "locale",
             "locale to use when running the program",
@@ -530,8 +530,17 @@ int TestApp::OnRun()
 
     if ( m_registries.empty() )
     {
-        // run or list all tests
+        // run or list all tests which use the CPPUNIT_TEST_SUITE_REGISTRATION() macro
+        // (i.e. those registered in the "All tests" registry); if there are other
+        // tests not registered with the CPPUNIT_TEST_SUITE_REGISTRATION() macro
+        // then they won't be listed/run!
         AddTest(runner, TestFactoryRegistry::getRegistry().makeTest());
+
+        if (m_list)
+        {
+            cout << "\nNote that the list above is not complete as it doesn't include the \n";
+            cout << "tests disabled by default.\n";
+        }
     }
     else // run only the selected tests
     {
index 671b606b8ba1784cfd2ea729c0893c2ad0ec2cf5..67ccec84b963ba818786130443abae5e4d577d77 100644 (file)
@@ -75,8 +75,9 @@ private:
     DECLARE_NO_COPY_CLASS(FTPTestCase)
 };
 
-// register in the unnamed registry so that these tests are run by default
-CPPUNIT_TEST_SUITE_REGISTRATION( FTPTestCase );
+// NOTE: we do not run FTPTestCase suite by default because buildslaves typically
+//       do not have FTP connectivity enabled by default...
+//CPPUNIT_TEST_SUITE_REGISTRATION( FTPTestCase );
 
 // also include in it's own registry so that these tests can be run alone
 CPPUNIT_TEST_SUITE_NAMED_REGISTRATION( FTPTestCase, "FTPTestCase" );