summaryrefslogtreecommitdiffstats
path: root/tests/auto/qdatetimeedit
diff options
context:
space:
mode:
authorJason McDonald <jason.mcdonald@nokia.com>2011-04-12 14:53:36 +1000
committerJason McDonald <jason.mcdonald@nokia.com>2011-04-12 15:38:20 +1000
commit3475168550c1a804f04f2a4edfeb30c04cd36551 (patch)
treeec1587bdc87e6f554c31e09cb1a3a2e26f16b181 /tests/auto/qdatetimeedit
parent78722d6b6e9ba0f6de1a4eba232aad2f96a339f2 (diff)
Reduce usage of Q_ASSERT in autotests.
Using Q_ASSERT does nothing in release-mode builds, and in debug builds it causes tests to terminate prematurely. It is much better to use QVERIFY or QCOMPARE. Task-number: QTBUG-17582 Reviewed-by: Rohan McGovern
Diffstat (limited to 'tests/auto/qdatetimeedit')
-rw-r--r--tests/auto/qdatetimeedit/tst_qdatetimeedit.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/auto/qdatetimeedit/tst_qdatetimeedit.cpp b/tests/auto/qdatetimeedit/tst_qdatetimeedit.cpp
index c8c3b90712..98632ae853 100644
--- a/tests/auto/qdatetimeedit/tst_qdatetimeedit.cpp
+++ b/tests/auto/qdatetimeedit/tst_qdatetimeedit.cpp
@@ -2751,7 +2751,7 @@ void tst_QDateTimeEdit::setCurrentSection()
QFETCH(QList<int>, setCurrentSections);
QFETCH(QList<int>, expectedCursorPositions);
- Q_ASSERT(setCurrentSections.size() == expectedCursorPositions.size());
+ QCOMPARE(setCurrentSections.size(), expectedCursorPositions.size());
testWidget->setDisplayFormat(format);
testWidget->setDateTime(dateTime);
#ifdef Q_WS_MAC