diff options
author | Peter Varga <pvarga@inf.u-szeged.hu> | 2016-09-08 16:39:47 +0200 |
---|---|---|
committer | Peter Varga <pvarga@inf.u-szeged.hu> | 2016-09-13 13:31:26 +0000 |
commit | 4688a73f9bc8aab8f64ae8eee64d19e7bb5f63b7 (patch) | |
tree | c5e2a31c4ddedc5cf63e08bde36cc878aa1e3d37 | |
parent | a1db2b655d40a5b154b313d7f789799480841e94 (diff) |
Fix test_scrollPositionAfterReload quick auto test
Wait for scroll position change before reload.
Task-number: QTBUG-55855
Change-Id: Ia42af1a4a76b2c507f4a88b39a469e3e37184ef7
Reviewed-by: Adam Kallai <kadam@inf.u-szeged.hu>
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
-rw-r--r-- | tests/auto/quick/qmltests/data/tst_scrollPosition.qml | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/tests/auto/quick/qmltests/data/tst_scrollPosition.qml b/tests/auto/quick/qmltests/data/tst_scrollPosition.qml index 08bb0f3b4..55b71189d 100644 --- a/tests/auto/quick/qmltests/data/tst_scrollPosition.qml +++ b/tests/auto/quick/qmltests/data/tst_scrollPosition.qml @@ -69,7 +69,11 @@ TestWebEngineView { tryCompare(webEngineView.scrollPosition, "y", 0); keyPress(Qt.Key_Return); // Focus is on the scroll button. - scrollPositionSpy.wait(); + + // Wait for proper scroll position change otherwise we cannot expect + // the new y position after reload. + tryCompare(webEngineView.scrollPosition, "x", 0); + tryCompare(webEngineView.scrollPosition, "y", 600); webEngineView.reload(); verify(webEngineView.waitForLoadSucceeded()); |