diff options
author | Ulf Hermann <ulf.hermann@qt.io> | 2019-01-24 11:23:48 +0100 |
---|---|---|
committer | Ulf Hermann <ulf.hermann@qt.io> | 2019-01-24 10:31:39 +0000 |
commit | ea463aa2cf8986664aeb9c1f9246aa32c4abbfff (patch) | |
tree | 214e7e49f5d82dbb3079ad8635cae64205a9298c /tests/auto | |
parent | 71c3abeda241b3a80781dfb610b09bca3fd52ace (diff) | |
download | qtquickcontrols-ea463aa2cf8986664aeb9c1f9246aa32c4abbfff.tar.gz |
ScrollView Tests: Allow for delayed update when loading new data
The ScrollView can render multiple times before the content is complete.
Change-Id: I32513a96e51c4d91e53daa6204821a95d9cb1d52
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Diffstat (limited to 'tests/auto')
-rw-r--r-- | tests/auto/controls/data/tst_scrollview.qml | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/tests/auto/controls/data/tst_scrollview.qml b/tests/auto/controls/data/tst_scrollview.qml index d3bfac4b..95aa6e98 100644 --- a/tests/auto/controls/data/tst_scrollview.qml +++ b/tests/auto/controls/data/tst_scrollview.qml @@ -197,8 +197,12 @@ TestCase { mouseRelease(scrollView, scrollView.width - 2, 8 + 16) waitForRendering(scrollView) - verify(Math.round(scrollView.flickableItem.contentHeight) > 60 * 20) - verify(Math.round(scrollView.flickableItem.contentY) < -(60 * 20)) + tryVerify( + function() { return Math.round(scrollView.flickableItem.contentHeight) > 60 * 20 }, + 50, "contentHeight did not adjust to new data.") + tryVerify( + function() { return Math.round(scrollView.flickableItem.contentY) < -(60 * 20) }, + 50, "contentY did not adjust to new data.") scrollView.destroy() } |