qt6-bb10/src/testlib
Ulf Hermann 81c92aec66 QTestLog: Properly own the loggers
Previously, the loggers would leak if the application failed to call
stopLogging(). Now they are owned by the global static which will delete
them in that case.

Also, since we have to adapt loggerCount() to the fact that std::vector
uses size_t, recognize that we only ever want to know whether the number
of loggers is 0. Change the method to only provide that information
rather than the actual number.

Change-Id: Ieb2e185048d573ec7f36373ad49bb2a0ca391ce3
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2021-11-09 21:36:50 +01:00
..
3rdparty Update 3rdparty valgrind headers to Valgrind 3.14.0 2018-10-17 11:26:08 +00:00
doc Doc: Enable qdoc warning count limit 2021-10-21 19:10:52 +02:00
CMakeLists.txt testlib: Replace custom QTestCoreList with std::vector 2021-09-10 22:19:45 +02:00
configure.cmake CMake: Regenerate configure.cmake files to get reports 2020-03-09 23:09:02 +01:00
qabstractitemmodeltester.cpp Update QAbstractItemModelTester::FailureReportingMode documentation 2021-08-01 12:44:14 +02:00
qabstractitemmodeltester.h Fix use of deprecated ItemDataRoles Background/TextColorRole 2018-11-05 21:58:37 +00:00
qabstracttestlogger.cpp Tidy up QTest::qt_asprintf() and remove a spurious declaration 2021-10-01 19:24:31 +02:00
qabstracttestlogger_p.h testlib: Rename QAbstractTestLogger::QSystem to QCritical 2021-08-10 18:06:36 +02:00
qappletestlogger.cpp testlib: Rename QAbstractTestLogger::QSystem to QCritical 2021-08-10 18:06:36 +02:00
qappletestlogger_p.h Another round of replacing 0 with nullptr 2020-10-07 23:02:47 +02:00
qasciikey.cpp Canonical pointer usage 2021-02-09 10:27:14 +08:00
qbenchmark.cpp QTestLib: Fix various clang warnings 2019-07-29 20:43:26 +02:00
qbenchmark.h Testlib: Rename qtest_global.h to qttestglobal.h 2018-03-21 10:31:01 +00:00
qbenchmark_p.h Replace discouraged Q_MOVABLE_TYPE by Q_RELOCATABLE_TYPE 2020-11-30 17:16:21 +01:00
qbenchmarkevent.cpp QTestLib: Fix class declarations/structure 2019-07-11 14:42:04 +02:00
qbenchmarkevent_p.h QTestLib: Use member initialization 2019-07-11 14:40:29 +02:00
qbenchmarkmeasurement.cpp
qbenchmarkmeasurement_p.h QTestLib: Fix various clang warnings 2019-07-29 20:43:26 +02:00
qbenchmarkmetric.cpp Fix build for Android with android-clang in r17 2018-06-06 11:36:33 +00:00
qbenchmarkmetric.h Testlib: Rename qtest_global.h to qttestglobal.h 2018-03-21 10:31:01 +00:00
qbenchmarkmetric_p.h Testlib: Rename qtest_global.h to qttestglobal.h 2018-03-21 10:31:01 +00:00
qbenchmarkperfevents.cpp QTestLib: Introduce nullptr 2019-07-11 14:41:50 +02:00
qbenchmarkperfevents_p.h QTestLib: Fix various clang warnings 2019-07-29 20:43:26 +02:00
qbenchmarktimemeasurers_p.h
qbenchmarkvalgrind.cpp Properly deprecate QProcess::pid 2020-10-01 04:55:47 +02:00
qbenchmarkvalgrind_p.h Make QStringList an alias to QList<QString> 2020-09-12 23:37:15 +02:00
qcsvbenchmarklogger.cpp QTestLib: Fix class declarations/structure 2019-07-11 14:42:04 +02:00
qcsvbenchmarklogger_p.h More nullptr usage in headers 2019-03-14 07:37:52 +00:00
qemulationdetector_p.h Move QEMU emulation detector to QTest 2021-02-13 10:02:51 +02:00
qjunittestlogger.cpp testlib: Gracefully handle messages outside of test function in JUnit reporter 2021-09-16 11:22:50 +02:00
qjunittestlogger_p.h testlib: Replace custom QTestCoreList with std::vector 2021-09-10 22:19:45 +02:00
qplaintestlogger.cpp testlib: Rename QAbstractTestLogger::QSystem to QCritical 2021-08-10 18:06:36 +02:00
qplaintestlogger_p.h More nullptr usage in headers 2019-03-14 07:37:52 +00:00
qpropertytesthelper_p.h Include qproperty.h where needed 2021-11-04 21:45:02 +01:00
qsignaldumper.cpp Deprecate the static int based API in QMetaType 2020-08-24 00:19:05 +02:00
qsignaldumper_p.h testlib: Defer signal dumper start until tests are ready to run 2020-07-22 23:23:16 +02:00
qsignalspy.h QSignalSpy: Use QMetaType instead of metatype id in initArgs 2020-11-10 11:23:55 +01:00
qsignalspy.qdoc Doc: Correct non-link related qdoc compilation errors 2020-01-14 16:38:48 +00:00
qt_cmdline.cmake CMake: Re-implement configure/qmake's command line handling in CMake 2020-08-17 08:08:20 +02:00
qtaptestlogger.cpp testlib: Don't report additional 'pass' test point for blacklisted XFail 2021-08-05 03:58:50 +02:00
qtaptestlogger_p.h Remove unnecessary ; after function implementations 2020-07-06 11:46:39 +02:00
qteamcitylogger.cpp testlib: Rename QAbstractTestLogger::QSystem to QCritical 2021-08-10 18:06:36 +02:00
qteamcitylogger_p.h More nullptr usage in headers 2019-03-14 07:37:52 +00:00
qtest.h QTest: support initMain() in QTEST_APPLESS_MAIN 2021-10-05 21:53:10 +02:00
qtest_gui.h QTest: there's no toString(QImage) 2021-07-07 15:07:55 +02:00
qtest_network.h doc: fix signatures and missing module headers 2017-12-14 13:37:51 +00:00
qtest_widgets.h
qtestaccessible.h QTestAccessible: Clear objects in EventList when deleted 2021-05-23 10:46:03 +00:00
qtestassert.h Fix modernize-use-bool-literals issues 2017-07-08 11:49:55 +00:00
qtestblacklist.cpp testlib: Only consider major version for macOS 11 and later in blacklists 2021-02-03 19:21:01 +00:00
qtestblacklist_p.h Bring QTestPrivate::checkBlackLists() back 2018-10-15 17:30:57 +00:00
qtestcase.cpp QTestLog: Properly own the loggers 2021-11-09 21:36:50 +01:00
qtestcase.h Deprecate QTest::qWarn() and replace its last use 2021-09-23 16:57:03 +02:00
qtestcase.qdoc Clarify documentation of QEXPECT_FAIL()'s mode 2021-08-11 21:10:00 +02:00
qtestcoreelement_p.h testlib: Replace custom QTestCoreList with std::vector 2021-09-10 22:19:45 +02:00
qtestdata.cpp Deprecate the static int based API in QMetaType 2020-08-24 00:19:05 +02:00
qtestdata.h Testlib: Rename qtest_global.h to qttestglobal.h 2018-03-21 10:31:01 +00:00
qtestelement.cpp testlib: Replace custom QTestCoreList with std::vector 2021-09-10 22:19:45 +02:00
qtestelement_p.h testlib: Replace custom QTestCoreList with std::vector 2021-09-10 22:19:45 +02:00
qtestelementattribute.cpp testlib: Remove unused QTestCoreElement and QTestElementAttribute types 2021-08-10 16:06:36 +00:00
qtestelementattribute_p.h testlib: Replace custom QTestCoreList with std::vector 2021-09-10 22:19:45 +02:00
qtestevent.h Use Q_DECL_UNUSED_MEMBER instead of Q_UNUSED 2020-07-06 11:29:39 +02:00
qtestevent.qdoc Doc: Fix linking errors qtbase 2019-01-03 09:45:23 +00:00
qtesteventloop.h QTestEventLoop: stop when the test fails 2021-08-05 01:07:41 +02:00
qtesthelpers_p.h testlib: start sharing common helper functions 2017-11-04 20:11:22 +00:00
qtestjunitstreamer.cpp testlib: Replace custom QTestCoreList with std::vector 2021-09-10 22:19:45 +02:00
qtestjunitstreamer_p.h QTestJunitStreamer: Include <vector> 2021-09-13 17:13:32 +02:00
qtestkeyboard.h Replace QTest::qWarn() with qWarning() 2021-09-23 16:57:03 +02:00
qtestlog.cpp QTestLog: Properly own the loggers 2021-11-09 21:36:50 +01:00
qtestlog_p.h QTestLog: Properly own the loggers 2021-11-09 21:36:50 +01:00
qtestmouse.cpp Remove QTest::lastMouseButton 2020-11-11 09:12:35 +01:00
qtestmouse.h Implement QTest:mouseMove widget overload to send event 2021-10-30 11:46:03 +02:00
qtestresult.cpp testlib: Let loggers know which test function is being left 2021-08-10 18:06:36 +02:00
qtestresult_p.h testlib: Pass on file location on failure, but don't assume we have one 2021-08-04 17:31:51 +00:00
qtestspontaneevent.h Cleanup qtestspontaneevent.h for Qt 6 2020-07-06 09:30:22 +00:00
qtestsystem.h testlib: Move qtestsystem helpers to their respective modules 2018-07-16 15:30:30 +00:00
qtesttable.cpp QTestLib: Introduce nullptr 2019-07-11 14:41:50 +02:00
qtesttable_p.h Testlib: Rename qtest_global.h to qttestglobal.h 2018-03-21 10:31:01 +00:00
qtesttouch.h Refactor testlib touch functions into qtestsupport_gui and _widgets 2020-09-08 08:02:15 +02:00
qtestutil_macos.mm testlib: Be more selective in choosing to show stacktraces on macOS 2020-02-06 23:42:55 +01:00
qtestutil_macos_p.h testlib: Be more selective in choosing to show stacktraces on macOS 2020-02-06 23:42:55 +01:00
qttestglobal.h Migrate to autogenerated cpp exports 2021-06-25 19:33:12 +02:00
qxctestlogger.mm Another round of replacing 0 with nullptr 2020-10-07 23:02:47 +02:00
qxctestlogger_p.h Another round of replacing 0 with nullptr 2020-10-07 23:02:47 +02:00
qxmltestlogger.cpp Use %.6g rather than %s and QByteArray::number() 2021-10-01 19:24:31 +02:00
qxmltestlogger_p.h Clean up QXmlTestLogger's xmlQuote() and xmlCdata() 2021-10-01 19:24:31 +02:00
selfcover.cmake CMake: Regenerate projects to use new qt_internal_ API 2020-09-23 16:59:06 +02:00