summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJason McDonald <jason.mcdonald@nokia.com>2010-12-23 03:14:06 (GMT)
committerJason McDonald <jason.mcdonald@nokia.com>2010-12-23 03:14:06 (GMT)
commite1ac82f713ab2a766ae518f3ec7a7f76689acb48 (patch)
tree04a7b3394eafdadf58fbb1a698da82b13488b31e
parent6e53095c6eb68c500d15b5ce9e86bafe5a2a0074 (diff)
downloadQt-e1ac82f713ab2a766ae518f3ec7a7f76689acb48.zip
Qt-e1ac82f713ab2a766ae518f3ec7a7f76689acb48.tar.gz
Qt-e1ac82f713ab2a766ae518f3ec7a7f76689acb48.tar.bz2
Improve docs for QTEST_MAIN macro.
The macro doesn't always create a QApplication, it depends on whether QT_GUI_LIB is defined. Task-number: QTBUG-3899 Reviewed-by: Rohan McGovern
-rw-r--r--src/testlib/qtestcase.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/testlib/qtestcase.cpp b/src/testlib/qtestcase.cpp
index e3a8726..207873e 100644
--- a/src/testlib/qtestcase.cpp
+++ b/src/testlib/qtestcase.cpp
@@ -298,10 +298,14 @@ QT_BEGIN_NAMESPACE
\relates QTest
- Implements a main() function that instantiates a QApplication object and
+ Implements a main() function that instantiates an application object and
the \a TestClass, and executes all tests in the order they were defined.
Use this macro to build stand-alone executables.
+ If \c QT_GUI_LIB is defined, the application object will be a QApplication,
+ otherwise it will be a QCoreApplication. If qmake is used and the configuration
+ includes \c{QT += gui}, then \c QT_GUI_LIB will be defined automatically.
+
\bold {Note:} On platforms that have keypad navigation enabled by default (eg: Symbian),
this macro will forcfully disable it to simplify the usage of key events when writing
autotests. If you wish to write a test case that uses keypad navigation, you should