diff options
| author | Ed Baak <ed.baak@nokia.com> | 2010-07-23 09:49:19 +1000 |
|---|---|---|
| committer | Ed Baak <ed.baak@nokia.com> | 2010-07-23 09:49:19 +1000 |
| commit | decbc60035f65acaa1c225ea9a7ba4fb8634f0b9 (patch) | |
| tree | 346e77d7404b501be05562a76b6e665acef5c94f /libqsystemtest/qabstracttest.cpp | |
| parent | 2a10573f0d67739b3fdec31787016a6a3ec99126 (diff) | |
Tweak code so that we can import it in creator-qtest - AND - continue to support a command line version of qtuitestrunner.
Diffstat (limited to 'libqsystemtest/qabstracttest.cpp')
| -rw-r--r-- | libqsystemtest/qabstracttest.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/libqsystemtest/qabstracttest.cpp b/libqsystemtest/qabstracttest.cpp index 0b0a5a5..bf6ea0b 100644 --- a/libqsystemtest/qabstracttest.cpp +++ b/libqsystemtest/qabstracttest.cpp @@ -305,6 +305,7 @@ QString QAbstractTest::currentTestFunction( bool fullName ) const return fullName ? (testCaseName() + "::" + QTest::currentTestFunction()) : (QTest::currentTestFunction()); } +#ifndef QTCREATOR_QTEST /* \internal Executes all test functions as specified on the command line, while running the @@ -337,7 +338,9 @@ int QAbstractTest::exec( int argc, char* argv[], char* filename ) delete[] _argv; return ret; } +#endif +#ifndef QTCREATOR_QTEST /* \internal Print a usage message. @@ -383,6 +386,7 @@ void QAbstractTest::printUsage( int argc, char* argv[] ) const " of the directory containing the test source file, then in $HOME/.qtest\n" , (argc) ? argv[0] : "test"); } +#endif /* \internal @@ -451,8 +455,10 @@ void QAbstractTest::processCommandLine( int &argc, char* argv[] ) !strcasecmp(argv[i], "-h") ) { argv[i] = 0; offset++; +#ifndef QTCREATOR_QTEST printUsage(argc-offset, argv); exit(0); +#endif // Silently ignore a few system test specific arguments. // For compatibility, we'll silently ignore these so that @@ -495,6 +501,7 @@ void handle_segfault(int signum) } #endif +# ifndef QTCREATOR_QTEST /* \internal Run test with arguments \a argc, \a argv, and return an exit code. @@ -511,6 +518,7 @@ int QAbstractTest::runTest(int argc, char *argv[]) return QTest::qExec( this, argc, argv ); return -1; } +#endif /*! \internal |
