summaryrefslogtreecommitdiffstats
path: root/tests/auto/testlib/selftests/tst_selftests.cpp
diff options
context:
space:
mode:
authorJason McDonald <jason.mcdonald@nokia.com>2011-09-20 11:56:31 +1000
committerQt by Nokia <qt-info@nokia.com>2011-09-20 08:46:18 +0200
commit01ece201ab08804c4ab226a39f1e1885aeaae0bd (patch)
tree9df4c2416e4470f30b62d112f822d882f0fafc64 /tests/auto/testlib/selftests/tst_selftests.cpp
parentd60007744bbc1cd90dcf97461a5b2fb237a82d17 (diff)
Split subtest selftest
This test was attempting to verify two completely unrelated things, so this commit splits it into two tests. Also, printf calls are replaced by qDebug so that the test does not bypass the testlib loggers. Change-Id: I1a202af38ce2c69690a32d93405ba604ec6cabee Reviewed-on: http://codereview.qt-project.org/5178 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
Diffstat (limited to 'tests/auto/testlib/selftests/tst_selftests.cpp')
-rw-r--r--tests/auto/testlib/selftests/tst_selftests.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/auto/testlib/selftests/tst_selftests.cpp b/tests/auto/testlib/selftests/tst_selftests.cpp
index 9c9d281478..bd0594dbcf 100644
--- a/tests/auto/testlib/selftests/tst_selftests.cpp
+++ b/tests/auto/testlib/selftests/tst_selftests.cpp
@@ -189,6 +189,7 @@ void tst_Selftests::runSubTest_data()
<< "maxwarnings"
<< "cmptest"
// << "alive" // timer dependent
+ << "float"
<< "globaldata"
<< "skipglobal"
<< "skip"
@@ -287,7 +288,7 @@ void tst_Selftests::runSubTest_data()
}
// this test prints out some floats in the testlog and the formatting is
// platform-specific and hard to predict.
- if (subtest == "subtest") {
+ if (subtest == "float") {
continue;
}
}
@@ -417,7 +418,7 @@ void tst_Selftests::doRunSubTest(QString const& subdir, QString const& logger, Q
if (expected.startsWith(QLatin1String("FAIL! : tst_Exception::throwException() Caught unhandled exce")) && expected != output)
// On some platforms we compile without RTTI, and as a result we never throw an exception.
QCOMPARE(output.simplified(), QString::fromLatin1("tst_Exception::throwException()").simplified());
- else if (output != expected && qstrcmp(QTest::currentDataTag(), "subtest") == 0)
+ else if (output != expected && qstrcmp(QTest::currentDataTag(), "float") == 0)
// The floating point formatting differs between platforms, so let's just skip it.
continue;
else if (benchmark || line.startsWith("<BenchmarkResult")) {