aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/declarative/qsglistview
diff options
context:
space:
mode:
authorMartin Jones <martin.jones@nokia.com>2011-07-11 13:47:51 +1000
committerQt by Nokia <qt-info@nokia.com>2011-07-12 06:38:09 +0200
commit4442dea01b9d4d45964228ac442166d89f091f9e (patch)
tree28ae20cb26967765a988b1ee522fc2d64d777671 /tests/auto/declarative/qsglistview
parentb119220da60453ecf31898f7a57eda9d3c4e9225 (diff)
Extract all QtQuick 1 elements into a separate library/plugin.
Change-Id: I41a280de2739ee08202f4be2519e5012870090f2 Reviewed-on: http://codereview.qt.nokia.com/1391 Reviewed-by: Martin Jones <martin.jones@nokia.com>
Diffstat (limited to 'tests/auto/declarative/qsglistview')
-rw-r--r--tests/auto/declarative/qsglistview/data/displaylist.qml2
-rw-r--r--tests/auto/declarative/qsglistview/tst_qsglistview.cpp12
2 files changed, 7 insertions, 7 deletions
diff --git a/tests/auto/declarative/qsglistview/data/displaylist.qml b/tests/auto/declarative/qsglistview/data/displaylist.qml
index c083da5aa5..4e8fd32f6a 100644
--- a/tests/auto/declarative/qsglistview/data/displaylist.qml
+++ b/tests/auto/declarative/qsglistview/data/displaylist.qml
@@ -13,7 +13,7 @@ Rectangle {
id: wrapper
objectName: "wrapper"
height: root.delegateHeight
- Behavior on height { NumberAnimation {} }
+ Behavior on height { NumberAnimation { duration: 200} }
width: 240
Text {
text: index
diff --git a/tests/auto/declarative/qsglistview/tst_qsglistview.cpp b/tests/auto/declarative/qsglistview/tst_qsglistview.cpp
index 22743b6f45..3abca71182 100644
--- a/tests/auto/declarative/qsglistview/tst_qsglistview.cpp
+++ b/tests/auto/declarative/qsglistview/tst_qsglistview.cpp
@@ -1761,7 +1761,7 @@ void tst_QSGListView::modelChanges()
listView->setModel(QVariant());
QTRY_COMPARE(modelSpy.count(),2);
-// delete canvas;
+ delete canvas;
}
void tst_QSGListView::QTBUG_9791()
@@ -2232,12 +2232,12 @@ void tst_QSGListView::resizeDelegate()
qApp->processEvents();
QSGListView *listview = findItem<QSGListView>(canvas->rootObject(), "list");
- QTRY_VERIFY(listview != 0);
+ QVERIFY(listview != 0);
QSGItem *contentItem = listview->contentItem();
- QTRY_VERIFY(contentItem != 0);
+ QVERIFY(contentItem != 0);
- QTRY_COMPARE(listview->count(), model.rowCount());
+ QCOMPARE(listview->count(), model.rowCount());
listview->setCurrentIndex(25);
listview->setContentY(0);
@@ -2252,7 +2252,7 @@ void tst_QSGListView::resizeDelegate()
QTRY_COMPARE(listview->highlightItem()->y(), 500.0);
canvas->rootObject()->setProperty("delegateHeight", 30);
- qApp->processEvents();
+ QTest::qWait(300);
for (int i = 0; i < 11; ++i) {
QSGItem *item = findItem<QSGItem>(contentItem, "wrapper", i);
@@ -2277,7 +2277,7 @@ void tst_QSGListView::resizeDelegate()
QTRY_COMPARE(listview->highlightItem()->y(), 30.0);
canvas->rootObject()->setProperty("delegateHeight", 20);
- qApp->processEvents();
+ QTest::qWait(300);
for (int i = 5; i < 11; ++i) {
QSGItem *item = findItem<QSGItem>(contentItem, "wrapper", i);