summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSzabolcs David <davidsz@inf.u-szeged.hu>2014-08-04 06:47:16 -0700
committerSzabolcs David <davidsz@inf.u-szeged.hu>2014-08-04 16:04:02 +0200
commit202d2ac93c4b4d6aed49eaa5793c35a9071f4602 (patch)
tree653aa88168c67337696b4fc841673af3e369e1c8
parent1c2a4da1c73bfc2456c59146ce615b7e2122e90e (diff)
Fix tst_QWebEngineFrame::setUrlWithFragment test
Change this test to rely on urlChanged() instead loadFinished(), because we don't get loadFinished signal if the load was handled by the same page. Change-Id: I65aa06afa4512fa845074ad97b87ecba16da687e Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
-rw-r--r--tests/auto/widgets/qwebengineframe/tst_qwebengineframe.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/tests/auto/widgets/qwebengineframe/tst_qwebengineframe.cpp b/tests/auto/widgets/qwebengineframe/tst_qwebengineframe.cpp
index 3846e50c9..1fc4aaea5 100644
--- a/tests/auto/widgets/qwebengineframe/tst_qwebengineframe.cpp
+++ b/tests/auto/widgets/qwebengineframe/tst_qwebengineframe.cpp
@@ -1256,16 +1256,17 @@ void tst_QWebEngineFrame::setUrlWithFragment()
QCOMPARE(page.url(), previousUrl);
}
- QSignalSpy spy(&page, SIGNAL(loadFinished(bool)));
+ QSignalSpy spy(&page, SIGNAL(urlChanged(QUrl)));
const QUrl url("qrc:/test1.html#");
QVERIFY(!url.fragment().isNull());
page.setUrl(url);
- ::waitForSignal(&page, SIGNAL(loadFinished(bool)));
+ ::waitForSignal(&page, SIGNAL(urlChanged(QUrl)));
QCOMPARE(spy.count(), 1);
QVERIFY(!toPlainTextSync(&page).isEmpty());
- QCOMPARE(page.requestedUrl(), url);
+ // Slight change: This information now comes from Chromium and the behavior of requestedUrl changed in this case.
+ // QCOMPARE(page.requestedUrl(), url);
QCOMPARE(page.url(), url);
}