diff options
author | Martin Negyokru <negyokru@inf.u-szeged.hu> | 2023-09-26 14:45:15 +0200 |
---|---|---|
committer | Martin Negyokru <negyokru@inf.u-szeged.hu> | 2023-09-28 13:47:27 +0000 |
commit | f19aa5e343db66e5baacacd3c360c4cb00a01c7c (patch) | |
tree | 97a552e9cf1d6d9c4fb680d41488f8af3490c224 /tests/auto/widgets/qwebenginehistory | |
parent | bd8572420779a916969fc2286e04269616348f71 (diff) |
Handle initial NavigationEntries
Chromium introduced the Initial NavigationEntry that meant to
represent the initial empty document at FrameTree creation time.
It is just a placeholder entry put in the list of NavigationEntries
that gets replaced on the next navigation.
A side effect of this is that we have an extra entry in the list before
we load any page.
This change also reverts the history related tests modified by
106 Adaptations that introduced this behavior.
Fixes: QTBUG-117489
Pick-to: 6.5 6.6
Change-Id: I2738591b681082792544bd884f8ecec54ce9d72d
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'tests/auto/widgets/qwebenginehistory')
-rw-r--r-- | tests/auto/widgets/qwebenginehistory/tst_qwebenginehistory.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/auto/widgets/qwebenginehistory/tst_qwebenginehistory.cpp b/tests/auto/widgets/qwebenginehistory/tst_qwebenginehistory.cpp index 6ddc031d5..ad66e972c 100644 --- a/tests/auto/widgets/qwebenginehistory/tst_qwebenginehistory.cpp +++ b/tests/auto/widgets/qwebenginehistory/tst_qwebenginehistory.cpp @@ -487,9 +487,9 @@ void tst_QWebEngineHistory::clear() QWebEnginePage page2(this); QWebEngineHistory* hist2 = page2.history(); - QCOMPARE(hist2->count(), 1); + QCOMPARE(hist2->count(), 0); hist2->clear(); - QCOMPARE(hist2->count(), 1); // Do not change anything. + QCOMPARE(hist2->count(), 0); // Do not change anything. } void tst_QWebEngineHistory::historyItemFromDeletedPage() |