diff options
author | Qt Continuous Integration System <qt-info@nokia.com> | 2010-07-28 03:28:17 (GMT) |
---|---|---|
committer | Qt Continuous Integration System <qt-info@nokia.com> | 2010-07-28 03:28:17 (GMT) |
commit | 104e9d2b3f8ac981a277cb0d63a1e5be8e352275 (patch) | |
tree | 86f6a8af556d23c46cf6d184a01a94c3a93cc873 | |
parent | 270beb4f8a5ca801e350d7e52e649fe2bd85022b (diff) | |
parent | 9d492514c9bd09fdb95984b71b7d5b46ceb0404b (diff) | |
download | Qt-104e9d2b3f8ac981a277cb0d63a1e5be8e352275.zip Qt-104e9d2b3f8ac981a277cb0d63a1e5be8e352275.tar.gz Qt-104e9d2b3f8ac981a277cb0d63a1e5be8e352275.tar.bz2 |
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/qt-multimedia-staging into 4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/qt-multimedia-staging:
Make tst_qdatetime failures more verbose.
-rw-r--r-- | tests/auto/qdatetime/tst_qdatetime.cpp | 56 |
1 files changed, 40 insertions, 16 deletions
diff --git a/tests/auto/qdatetime/tst_qdatetime.cpp b/tests/auto/qdatetime/tst_qdatetime.cpp index 0900b35..1a82a4c 100644 --- a/tests/auto/qdatetime/tst_qdatetime.cpp +++ b/tests/auto/qdatetime/tst_qdatetime.cpp @@ -961,14 +961,26 @@ void tst_QDateTime::currentDateTime() upperBound.setTime_t(buf2); upperBound = upperBound.addSecs(1); - QVERIFY(lowerBound < upperBound); - - QVERIFY(lowerBound <= dt1); - QVERIFY(dt1 < upperBound); - QVERIFY(lowerBound <= dt2); - QVERIFY(dt2 < upperBound); - QVERIFY(lowerBound <= dt3); - QVERIFY(dt3 < upperBound); + QString details = QString("\n" + "lowerBound: %1\n" + "dt1: %2\n" + "dt2: %3\n" + "dt3: %4\n" + "upperBound: %5\n") + .arg(lowerBound.toTime_t()) + .arg(dt1.toTime_t()) + .arg(dt2.toTime_t()) + .arg(dt3.toTime_t()) + .arg(upperBound.toTime_t()); + + QVERIFY2(lowerBound < upperBound, qPrintable(details)); + + QVERIFY2(lowerBound <= dt1, qPrintable(details)); + QVERIFY2(dt1 < upperBound, qPrintable(details)); + QVERIFY2(lowerBound <= dt2, qPrintable(details)); + QVERIFY2(dt2 < upperBound, qPrintable(details)); + QVERIFY2(lowerBound <= dt3, qPrintable(details)); + QVERIFY2(dt3 < upperBound, qPrintable(details)); QVERIFY(dt1.timeSpec() == Qt::LocalTime); QVERIFY(dt2.timeSpec() == Qt::LocalTime); @@ -1000,14 +1012,26 @@ void tst_QDateTime::currentDateTimeUtc() upperBound.setTime_t(buf2); upperBound = upperBound.addSecs(1); - QVERIFY(lowerBound < upperBound); - - QVERIFY(lowerBound <= dt1); - QVERIFY(dt1 < upperBound); - QVERIFY(lowerBound <= dt2); - QVERIFY(dt2 < upperBound); - QVERIFY(lowerBound <= dt3); - QVERIFY(dt3 < upperBound); + QString details = QString("\n" + "lowerBound: %1\n" + "dt1: %2\n" + "dt2: %3\n" + "dt3: %4\n" + "upperBound: %5\n") + .arg(lowerBound.toTime_t()) + .arg(dt1.toTime_t()) + .arg(dt2.toTime_t()) + .arg(dt3.toTime_t()) + .arg(upperBound.toTime_t()); + + QVERIFY2(lowerBound < upperBound, qPrintable(details)); + + QVERIFY2(lowerBound <= dt1, qPrintable(details)); + QVERIFY2(dt1 < upperBound, qPrintable(details)); + QVERIFY2(lowerBound <= dt2, qPrintable(details)); + QVERIFY2(dt2 < upperBound, qPrintable(details)); + QVERIFY2(lowerBound <= dt3, qPrintable(details)); + QVERIFY2(dt3 < upperBound, qPrintable(details)); QVERIFY(dt1.timeSpec() == Qt::UTC); QVERIFY(dt2.timeSpec() == Qt::LocalTime); |