From e1ac82f713ab2a766ae518f3ec7a7f76689acb48 Mon Sep 17 00:00:00 2001 From: Jason McDonald Date: Thu, 23 Dec 2010 13:14:06 +1000 Subject: 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 --- src/testlib/qtestcase.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) 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 -- cgit v0.12