summaryrefslogtreecommitdiffstats
path: root/tests/auto/widgets/qwebenginepage
Commit message (Collapse)AuthorAgeFilesLines
* Fix backActionUpdate flaky failureKirill Burtsev2020-02-041-1/+1
| | | | | | | | BackAction might not be immediatelly enabled after frame's content check through javascript. Amends d7d40469b5. Change-Id: I2b6242da190c39b8d72d17d563c6c86238e56887 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Blacklist tst_QWebEnginePage::mouseMovementProperties on macOSTor Arne Vestbø2020-01-231-0/+1
| | | | | | | | It relies on moving the cursor. Task-number: QTBUG-76312 Change-Id: I6bdd53b8c0eb41300a538137fb7ec52881c38f33 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Update navigation actions when load finishes in a subframePeter Varga2020-01-221-7/+26
| | | | | | | Fixes: QTBUG-81521 Change-Id: I8ca82224cd834b667471d1e96a44430164d3669e Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io>
* FIXUP: Un-blacklist tst_qwebenginepage::fullScreenRequested() on WindowsTamas Zakor2020-01-221-20/+40
| | | | | Change-Id: I3fc41f664bf79ff6379c943411f7d38d0b4fa962 Reviewed-by: Kirill Burtsev <kirill.burtsev@qt.io>
* Add qtry prefix to webenginepage testMichal Klocek2020-01-171-2/+2
| | | | | | | We got one failure at previous integration. Change-Id: Ic229a66bde151ea6a6a1805e38eb8e2f6f337107 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Rework url changed logicMichal Klocek2020-01-141-5/+6
| | | | | | | | | | | | | | | | | | | | | | Due security changes to prevent url spoofing, our implementation is getting extra invalidate url requests. Unfortunately, this breaks our url handling, which now gets lots of new back and fort url changed signals and make several unit test failures. After tedious investigation of Chromium omnibox handing and trying out different approaches, it seems that only sensible solution is to follow Chromium logic and make NavigationStateChanged to update 'ui' in asynchronous matter. This change tries not break any tests and simplify url handling. The only side effect of this change is that WebEnginePage::setContent will get extra 'url' signal of initial 'urlData' and later 'baseUrl' change is emitted. Fix one of qml tests which did not expect to have url on LoadStartedStatus. Task-number: QTBUG-63388 Task-number: QTBUG-48995 Change-Id: Id347f4325c036e16bfae7bf2f694905e0f21f8d7 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Un-blacklist tst_qwebenginepage::fullScreenRequested() on WindowsTamas Zakor2019-12-182-151/+22
| | | | | | | | | | | | | | | The JavaScriptCallbackWatcher::wait() blocks the callback and it gets called after the wait() only. Replace JavaScriptCallbackWatcher() with QTRY_COMPARE() and QTRY_VERIFY(). These functions don't block the callback call. Remove JavaScriptCallback class from test. Also reimplement tst_qwebenginepage::runJavaScript auto test. Fixes: QTBUG-78015 Change-Id: I11e6f709c00a9121066c2554508c8312c1e33c12 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Update find request id when a new search interrupts an ongoing searchPeter Varga2019-11-281-0/+13
| | | | | | | | | | | | | | | | | If the new test became flaky it might happen because the first text search finished before the second findText() call. This is very unlikely, but in this case the test should be modified to not to check if the first find failed. The point is to check we get the correct amount of signals and the second search doesn't assert. If the callbacks will be removed in Qt6, it should be re-considered to remove the "unfinished find" workaround and trigger the first successful findTextFinished() signal even if it happens in the middle of another search. Fixes: QTBUG-80086 Change-Id: I9c1ce20fc43fd81e8af784385a00ac2e7f7603b7 Reviewed-by: Kirill Burtsev <kirill.burtsev@qt.io>
* Fix renderProcessTerminated signalJüri Valdmann2019-11-281-0/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | With the adaptations for Chromium 76, RenderWidgetHostViewQt was changed to become a RenderProcessHostObserver with the renderProcessTerminated signal being emitted from the override of RenderProcessHostObserver::RenderProcessExited. The problem with this can be seen by setting a breakpoint on the RenderProcessGone override in RenderWidgetHostViewQt. We then get the trace: QtWebEngineCore::RenderWidgetHostViewQt::RenderProcessGone content::RenderWidgetHostImpl::RendererExited() content::RenderViewHostImpl::RenderProcessExited content::RenderProcessHostImpl::ProcessDied ProcessDied iterates over all the observers and calls RenderProcessExited. Both the RenderViewHostImpl and our RWHVQt are observers, but the RVHImpl comes first. The RVHImpl then calls RendererExited, which calls our RenderProcessGone, which does a 'delete this'. Now our RenderProcessExited override can never be called because we have already deleted our observer. Fix by moving the RenderProcessGone code to WebContentsDelegateQt and getting the exit code from WebContents::GetCrashedErrorCode. Also add test. Task-number: QTBUG-80085 Change-Id: I434744286df97a37b64722d7c15a1d4ee11c8af6 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Add tst_QWebEnginePage::setHtmlWithModuleImportJüri Valdmann2019-11-081-0/+36
| | | | | | | | Try importing JS modules from a setHtml page. Fixes: QTBUG-77282 Change-Id: I925bd3239688117c380ed3ae404dcb9547d99cac Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* More speculative fixes for MSVC 2019 CIv5.14.0-beta3Allan Sandfeld Jensen2019-11-061-21/+21
| | | | | | | | | Expand many more timeouts as loading basic test cases can now take many seconds. Task-number: QTBUG-79290 Change-Id: I749fe50525919b24a4a3fcba905745b6d6648121 Reviewed-by: Kirill Burtsev <kirill.burtsev@qt.io>
* Merge branch '5.13' into 5.14Allan Sandfeld Jensen2019-10-301-14/+27
|\ | | | | | | Change-Id: I6ab2e949cb2fa3b2db55a1654d42667db6257eab
| * Fix getDisplayMedia crashJüri Valdmann2019-10-171-14/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The MEDIA_DISPLAY_VIDEO_CAPTURE stream type is handled incorrectly by MediaCaptureDevicesDispatcher causing a crash when an unexpected type of media device is returned to Chromium. This patch only fixes the crash, screen sharing is nonetheless not properly supported by WebEngine due to limitations of the public API which does not allow selecting between screens, not to mention windows or tabs. On Linux WebRTC's ScreenCapturer is not even built since it depends on use_x11 being set in GN. Fixes: QTBUG-78016 Change-Id: I7fa49febaba1be94bdb6c31265dfc24ee809d635 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
| * Stabilize tst_QWebEnginePage::comboBoxPopupPositionAfterMove auto testPeter Varga2019-10-091-0/+6
| | | | | | | | | | | | | | | | Fixes a flaky fail when jsViewPosition is called too early to query the view position. Change-Id: Ib2e9c1e95a6363a8e45e8bcc44e1878fd9a6914f Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Improve QWebEngineFindTextResult APIv5.14.0-beta2Peter Varga2019-10-191-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | Implements suggestions from 5.14 API review: - Rename activeMatchOrdinal to activeMatch - Extend documentation - Change QML import version number to 1.10 Task-number: QTBUG-77839 Change-Id: I5eae659cfb5355af8d0c878d3b5f00654c9d6d13 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Fix tst_qwebenginepage::comboBoxPopupPositionAfterMove() auto testTamas Zakor2019-10-171-0/+2
| | | | | | | | | | | | | | | | | | | | | | Assertion fail occurs when the destruction order of the windows is not correct. This happens only in this test and can not be reproduced manually. Destroy popup window before destroying the main window. Change-Id: Iea00df25c200e1b8aff9ce08ef73a411e549fcab Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Merge remote-tracking branch 'origin/5.13' into 5.14Allan Sandfeld Jensen2019-09-242-10/+4
|\| | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: config.tests/glibc/glibc.cpp src/3rdparty src/core/configure.json src/core/profile_io_data_qt.cpp src/webengine/configure.json src/webenginewidgets/api/qwebenginepage.cpp tests/auto/widgets/qwebenginepage/BLACKLIST Change-Id: I3e1781048c3cb09bfbf7427dfc5dd1fec11a2b97
| * Fix flaky tst_QWebEnginePage::runJavaScriptFromSlotJüri Valdmann2019-09-142-9/+4
| | | | | | | | | | | | | | | | Unfortunately, "load finished" doesn't mean "ready to execute JavaScript". Fixes: QTBUG-74718 Change-Id: I611e35cfbb530ff68745d86124679d60ab0b113e Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* | Blacklist tst_QWebEnginePage::fullScreenRequested on WindowsAllan Sandfeld Jensen2019-09-061-0/+3
| | | | | | | | | | | | Task-number: QTBUG-78015 Change-Id: I9d1e2409897df6d5a36ab9a12d42224c2163df6b Reviewed-by: Liang Qi <liang.qi@qt.io>
* | Introduce findTextFinished signalPeter Varga2019-08-231-12/+101
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a replacement for the callbacks. Also introduces QWebEngineFindTextResult class what is common for the Quick and Widget APIs. This makes possible to provide extra information about the match, eg. the number of matches and the index of the currently highlighted match. [ChangeLog][QtWebEngine][WebEngineView] Introduces findTextFinished signal and FindTextResult type to provide extra information about the result of a text search. [ChangeLog][QtWebEngineWidgets][QWebEnginePage] Introduces findTextFinished signal and QWebEngineFindTextResult class to provide extra information about the result of a text search. Task-number: QTBUG-50420 Change-Id: Icb9737d2f596e6bc0fc5733144eeeaf2a77aab02 Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io>
* | Refactor findText handlingPeter Varga2019-08-221-0/+23
| | | | | | | | | | | | | | | | | | | | | | Move most of the findText logic to the QtWebEngineCore::FindTextHelper class. This change also separates findText callbacks in the new class for getting rid of the request ID conversion and make it easier to remove them in Qt6. Task-number: QTBUG-50420 Change-Id: I348cedd0f90a49f9b360165c46319aeed2c236c0 Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io>
* | Merge remote-tracking branch 'origin/5.13' into devAllan Sandfeld Jensen2019-07-241-0/+66
|\| | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/3rdparty src/core/core_chromium.pri tests/auto/quick/qmltests/BLACKLIST tests/auto/quick/qquickwebengineview/BLACKLIST tests/auto/widgets/qwebenginepage/BLACKLIST tests/auto/widgets/qwebenginepage/tst_qwebenginepage.cpp tests/auto/widgets/qwebengineview/BLACKLIST Change-Id: I11b26f5eebde29c4c62247b90e11e3ae40789fe4
| * Merge remote-tracking branch 'origin/5.12' into 5.13Allan Sandfeld Jensen2019-07-102-3/+66
| |\ | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf tests/auto/quick/qmltests/BLACKLIST tests/auto/quick/qquickwebengineview/BLACKLIST Change-Id: I29b68dec8692d0369a2dda56350ee62d3ad73e08
| | * Wait for SelectAll to be enabled in tst_QWebEnginePage::findTextJüri Valdmann2019-07-091-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | Fixes flaky m_view->hasSelection() assertion. Change-Id: Idba17916c38ac76b8002e30bab08d7f9e1064b2a Reviewed-by: Kirill Burtsev <kirill.burtsev@qt.io> Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
| | * Un-blacklist some passing testsJüri Valdmann2019-07-081-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | Remove from the blacklist some tests which, according to Grafana, have had no failures in the last 90 days on 5.12 branch. Change-Id: I3f174c82b5644d74b70fffa3856ae79f8c9893f8 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| | * Set custom user-agent manually on new windowsAllan Sandfeld Jensen2019-06-071-0/+65
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Chromium forgets to set ShouldOverrideUserAgentInNewTabs(), so we need to manually set the override. Fixes: QTBUG-76249 Change-Id: Id240ee525dacec3cd8389aca058a61d3af62b00a Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* | | Merge "Merge remote-tracking branch 'origin/5.13' into dev"Allan Sandfeld Jensen2019-07-141-0/+3
|\ \ \
| * | | Merge remote-tracking branch 'origin/5.13' into devAllan Sandfeld Jensen2019-07-101-0/+3
| |\| | | | | | | | | | | | | | Change-Id: I156385925a060081cce7091da199266482aec5d8
| | * | Speculative fix for flaky runJavaScriptFromSlot testJüri Valdmann2019-07-031-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-74718 Change-Id: Idb46521b94517b54d4c38624d4557fbe31565560 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
* | | | Adaptations for Chromium 75Allan Sandfeld Jensen2019-07-101-3/+3
|/ / / | | | | | | | | | | | | Change-Id: Idad08244e0c749a9f70f5eb9f8cd236039b941b3 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
* | | Disable Cut/Copy/Unselect actions when there's no selectionJüri Valdmann2019-07-081-0/+39
| | | | | | | | | | | | | | | | | | Fixes: QTBUG-76666 Change-Id: I74b9a26cd7be9a830f4eecd36db69777412ab316 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
* | | Merge remote-tracking branch 'origin/5.13' into devJüri Valdmann2019-07-021-2/+93
|\| | | | | | | | | | | Change-Id: I806417dd7a6d2594a86ee49feedc4ad9ee48add2
| * | Merge remote-tracking branch 'origin/5.12' into 5.13Allan Sandfeld Jensen2019-06-111-2/+93
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf src/3rdparty src/core/configure.json src/core/profile_io_data_qt.cpp tests/auto/widgets/qwebenginepage/tst_qwebenginepage.cpp Change-Id: Ie8ae4aa03881a0733ff497fff46e3f7040735650
| | * Disable edit actions when content has no focused framePeter Varga2019-05-271-2/+93
| | | | | | | | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-75505 Change-Id: Ia1329ff554a86e307aa7995e9af1665ea6c5e64c Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | | unblacklist passing testsDaniel Smith2019-06-281-9/+0
| | | | | | | | | | | | | | | | | | | | | | | | These tests have not failed on the removed platforms for at least 60 days Task-number: QTBUG-76608 Change-Id: I4f6cec6ff5e7408542085fd7ae8cecbe04b6fd28 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
* | | Merge "Merge remote-tracking branch 'origin/5.13' into dev"Allan Sandfeld Jensen2019-05-271-0/+12
|\ \ \
| * | | Merge remote-tracking branch 'origin/5.13' into devAllan Sandfeld Jensen2019-05-271-0/+12
| |\| | | | | | | | | | | | | | Change-Id: I70917458ba43c8fbf27fee2382eee42618588fe4
| | * | Merge remote-tracking branch 'origin/5.12' into 5.13Allan Sandfeld Jensen2019-05-241-0/+12
| | |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/3rdparty src/core/net/network_delegate_qt.cpp tests/auto/widgets/qwebenginedownloaditem/tst_qwebenginedownloaditem.cpp Change-Id: Ib715b3047213583e0441b915d3cabb801d9d4ba8
| | | * Update docs and test for runJavaScriptJüri Valdmann2019-05-091-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes: QTBUG-69567 Change-Id: Icdf5a200f7be1eb7a98cce62848e3a641c49e804 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* | | | Implement page lifecycle APIJüri Valdmann2019-05-243-0/+670
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | [ChangeLog][QtWebEngine][WebEngineView] WebEngineView now supports lifecycle states that can be used for reducing CPU and memory consumption of invisible views. [ChangeLog][QtWebEngineWidgets][QWebEnginePage] QWebEnginePage now supports lifecycle states that can be used for reducing CPU and memory consumption of invisible pages. Fixes: QTBUG-74166 Fixes: QTBUG-55079 Change-Id: I7d70c85dc995bd17c9fe91385a8e2750dbc0a627 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
* | | Add navigation type for redirectsAllan Sandfeld Jensen2019-05-101-1/+1
| | | | | | | | | | | | | | | | | | Fixes: QTBUG-74490 Change-Id: Ia8de7dbec717021f367133cebb8c118e333388e4 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
* | | Merge remote-tracking branch 'origin/5.13' into devAllan Sandfeld Jensen2019-05-091-0/+29
|\| | | | | | | | | | | Change-Id: I495adfcbb010ac29dc64e051c030a92d27859ca6
| * | Add unit test for verifying QWebEnginePage::contentsSize correctnessMichael Brüning2019-04-131-0/+29
| | | | | | | | | | | | | | | | | | | | | | | | An adaptation to Chromium 70 caused a regression in this. Change-Id: I8928694b9f99cd420afd858d3a1023228276bae0 Reviewed-by: Kirill Burtsev <kirill.burtsev@qt.io> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | | Blacklist runJavaScriptFromSlot on Linux tooAllan Sandfeld Jensen2019-04-121-0/+1
|/ / | | | | | | | | | | | | | | Now it fails on Linux as well. Task-number: QTBUG-75143 Change-Id: I4eeafb084d35278119aab0584fb5ffac196164f2 Reviewed-by: Liang Qi <liang.qi@qt.io>
* | Notification API cleanupKirill Burtsev2019-04-051-14/+20
| | | | | | | | | | | | Task-number: QTBUG-74543 Change-Id: Ice5a0dbfc3485c8b7e6fa900ef427a9aed871d42 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Remove our last uses of Q_DECL_OVERRIDE and Q_NULLPTRAllan Sandfeld Jensen2019-04-031-3/+3
| | | | | | | | | | Change-Id: I8806a3fb466006f14cf92f17510cdea8b50e8345 Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io>
* | Blacklist tst_QWebEnginePage::runJavaScriptFromSlot on macOSAllan Sandfeld Jensen2019-03-281-0/+3
| | | | | | | | | | | | | | | | | | This is our most flaky test at the moment Task-number: QTBUG-74718 Change-Id: Ia7668347a74982abfb0297169f564db89944e87c Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Merge remote-tracking branch 'origin/5.12' into 5.13Allan Sandfeld Jensen2019-03-203-1/+16
|\| | | | | | | Change-Id: If0a4c869d801fe94df23201391c30c1efc5000e0
| * Do not report client redirects as link-clickedAllan Sandfeld Jensen2019-03-193-1/+16
| | | | | | | | | | | | | | | | | | Fixes false navigation type on http-equiv refresh, and javascript redirects. Task-number: QTBUG-74490 Change-Id: Ie6fa5c94ae9642a7e9c689198a4977747f4101ce Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* | Notification API cleanup: direction type, parameter and method namesKirill Burtsev2019-03-191-1/+4
| | | | | | | | | | Change-Id: I0349f3eea0028a4df917af8599c073227e0d0ec1 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>