26c41ed918
Previously, ignored messages were only cleared at the end of each test function, i.e. after all data rows were finished. This meant that if a data row in a data-driven test function didn't cause all of the expected messages to be generated, the remaining messages would be carried over to the next data row. This would result in errors about missing messages being associated with the last data row rather than with the correct data row. This commit makes testlib check for missing ignored messages after running each data row rather than only doing so after the last data row. This commit also adds a regression test to demonstrate that ignored messages can no longer be carried over from one data row to another. Change-Id: Ibee51aa6e96866fbcbcb4acee1a8340a86a6a4ba Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
23 lines
1.4 KiB
Plaintext
23 lines
1.4 KiB
Plaintext
********* Start testing of tst_Warnings *********
|
|
Config: Using QTest library @INSERT_QT_VERSION_HERE@, Qt @INSERT_QT_VERSION_HERE@
|
|
PASS : tst_Warnings::initTestCase()
|
|
QWARN : tst_Warnings::testWarnings() Warning
|
|
QWARN : tst_Warnings::testWarnings() Warning
|
|
QDEBUG : tst_Warnings::testWarnings() Debug
|
|
QDEBUG : tst_Warnings::testWarnings() Debug
|
|
QDEBUG : tst_Warnings::testWarnings() Baba
|
|
QDEBUG : tst_Warnings::testWarnings() Baba
|
|
PASS : tst_Warnings::testWarnings()
|
|
INFO : tst_Warnings::testMissingWarnings() Did not receive message: "Warning0"
|
|
INFO : tst_Warnings::testMissingWarnings() Did not receive message: "Warning1"
|
|
FAIL! : tst_Warnings::testMissingWarnings() Not all expected messages were received
|
|
INFO : tst_Warnings::testMissingWarningsWithData(first row) Did not receive message: "Warning0"
|
|
INFO : tst_Warnings::testMissingWarningsWithData(first row) Did not receive message: "Warning1"
|
|
FAIL! : tst_Warnings::testMissingWarningsWithData(first row) Not all expected messages were received
|
|
INFO : tst_Warnings::testMissingWarningsWithData(second row) Did not receive message: "Warning0"
|
|
INFO : tst_Warnings::testMissingWarningsWithData(second row) Did not receive message: "Warning1"
|
|
FAIL! : tst_Warnings::testMissingWarningsWithData(second row) Not all expected messages were received
|
|
PASS : tst_Warnings::cleanupTestCase()
|
|
Totals: 3 passed, 3 failed, 0 skipped
|
|
********* Finished testing of tst_Warnings *********
|