diff options
author | Martin Jones <martin.jones@nokia.com> | 2010-10-14 04:57:43 (GMT) |
---|---|---|
committer | Martin Jones <martin.jones@nokia.com> | 2010-10-14 04:57:43 (GMT) |
commit | 1048ac9f491bf2e79c469d0451e437a1a485bef5 (patch) | |
tree | d9ea52ce522f8b69f8f2c8af9ebd7a9c03c420e6 /tests/auto/declarative | |
parent | bccb1a82fd796ca31b8b4777c29344bafc6d71d6 (diff) | |
parent | 896cf6f1523afcf5237efc1ca135672ca3cb8058 (diff) | |
download | Qt-1048ac9f491bf2e79c469d0451e437a1a485bef5.zip Qt-1048ac9f491bf2e79c469d0451e437a1a485bef5.tar.gz Qt-1048ac9f491bf2e79c469d0451e437a1a485bef5.tar.bz2 |
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/qt-qml into 4.7
Diffstat (limited to 'tests/auto/declarative')
-rw-r--r-- | tests/auto/declarative/qdeclarativelistmodel/tst_qdeclarativelistmodel.cpp | 10 | ||||
-rw-r--r-- | tests/auto/declarative/qdeclarativetext/data/alignments_cb.png | bin | 496 -> 496 bytes | |||
-rw-r--r-- | tests/auto/declarative/qdeclarativetext/data/alignments_cc.png | bin | 556 -> 556 bytes | |||
-rw-r--r-- | tests/auto/declarative/qdeclarativetext/data/alignments_ct.png | bin | 533 -> 533 bytes |
4 files changed, 10 insertions, 0 deletions
diff --git a/tests/auto/declarative/qdeclarativelistmodel/tst_qdeclarativelistmodel.cpp b/tests/auto/declarative/qdeclarativelistmodel/tst_qdeclarativelistmodel.cpp index be77f8e..4b8d772 100644 --- a/tests/auto/declarative/qdeclarativelistmodel/tst_qdeclarativelistmodel.cpp +++ b/tests/auto/declarative/qdeclarativelistmodel/tst_qdeclarativelistmodel.cpp @@ -320,11 +320,16 @@ void tst_qdeclarativelistmodel::dynamic() if (!warning.isEmpty()) QTest::ignoreMessage(QtWarningMsg, warning.toLatin1()); + QSignalSpy spyCount(&model, SIGNAL(countChanged())); + int actual = e.evaluate().toInt(); if (e.hasError()) qDebug() << e.error(); // errors not expected QCOMPARE(actual,result); + + if (model.count() > 0) + QVERIFY(spyCount.count() > 0); } void tst_qdeclarativelistmodel::dynamic_worker_data() @@ -351,6 +356,8 @@ void tst_qdeclarativelistmodel::dynamic_worker() QDeclarativeItem *item = createWorkerTest(&eng, &component, &model); QVERIFY(item != 0); + QSignalSpy spyCount(&model, SIGNAL(countChanged())); + if (script[0] == QLatin1Char('{') && script[script.length()-1] == QLatin1Char('}')) script = script.mid(1, script.length() - 2); QVariantList operations; @@ -367,6 +374,9 @@ void tst_qdeclarativelistmodel::dynamic_worker() waitForWorker(item); QCOMPARE(QDeclarativeProperty(item, "result").read().toInt(), result); + if (model.count() > 0) + QVERIFY(spyCount.count() > 0); + delete item; qApp->processEvents(); } diff --git a/tests/auto/declarative/qdeclarativetext/data/alignments_cb.png b/tests/auto/declarative/qdeclarativetext/data/alignments_cb.png Binary files differindex 99de219..cf6199a 100644 --- a/tests/auto/declarative/qdeclarativetext/data/alignments_cb.png +++ b/tests/auto/declarative/qdeclarativetext/data/alignments_cb.png diff --git a/tests/auto/declarative/qdeclarativetext/data/alignments_cc.png b/tests/auto/declarative/qdeclarativetext/data/alignments_cc.png Binary files differindex cb85251..f81ccb4 100644 --- a/tests/auto/declarative/qdeclarativetext/data/alignments_cc.png +++ b/tests/auto/declarative/qdeclarativetext/data/alignments_cc.png diff --git a/tests/auto/declarative/qdeclarativetext/data/alignments_ct.png b/tests/auto/declarative/qdeclarativetext/data/alignments_ct.png Binary files differindex ddca549..9ba6412 100644 --- a/tests/auto/declarative/qdeclarativetext/data/alignments_ct.png +++ b/tests/auto/declarative/qdeclarativetext/data/alignments_ct.png |