summaryrefslogtreecommitdiffstats
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
* Merge remote-tracking branch 'origin/5.15' into devMichael Brüning2020-07-246-4/+107
|\ | | | | | | | | | | | | | | | | Conflicts: src/core/compositor/delegated_frame_node.cpp src/core/core_chromium.pri src/core/render_widget_host_view_qt.cpp Change-Id: I9387151e9647c87fc387095e7b6d8d66560cdf71
| * Fix incorrect doc for acceptNavigationRequest and add testJüri Valdmann2020-07-221-0/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | The function is called for all navigation requests. The original bug report was most likely due to the use relative links on a page without a base url, which indeed results in no call to acceptNavigationRequest being made. But this has nothing to do with local vs remote URLs, it's rather that relative links, which are relative to nothing, are not valid links and there thus cannot be any navigation request either. Task-number: QTBUG-48435 Change-Id: I08bd0c86d67bf1dd1d7662468321777254a7db0b Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| * Add the cookie filter to URL requestsAllan Sandfeld Jensen2020-07-153-1/+74
| | | | | | | | | | | | | | | | | | | | Submodule src/3rdparty c91f4d20..809e16e4: > Add cookie filter to URL requests cookie headers > Use audio-manager app-name for MPRIS Fixes: QTBUG-85526 Change-Id: Icab26cad3cea8e2ee021a3e589f41bf0543d64fa Reviewed-by: Michael Brüning <michael.bruning@qt.io>
| * Replace qgetenv with qEnvironmentVariableAllan Sandfeld Jensen2020-06-301-1/+1
| | | | | | | | | | | | | | | | | | This preserves unicode characters in the environment variable on Windows. Fixes: QTBUG-85054 Change-Id: I3352cc3db4ce8d7b9b352c1634e3239954780618 Reviewed-by: Kirill Burtsev <kirill.burtsev@qt.io>
| * Return valid path in Profile::GetPath() for incognito profilesAllan Sandfeld Jensen2020-06-291-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | Parts of Chromium depends on it for temporary directories it creates. This also changes the logic of depending on it being empty as indicating an in memory profile, so it required a bit of cleaning up. Note this does subtly change the return value of off-the-record profiles. Task-number: QTBUG-62957 Change-Id: Iec6e24556128c515fce27803171a766b8a9d92e3 Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* | Replace Qt::MidButton with Qt::MiddleButtonEdward Welbourne2020-07-221-2/+2
| | | | | | | | | | | | | | | | | | | | The latter has been the preferred name since Qt 4.7.0. (Pick back to 5.15 shall need to drop the test change, as the test was added to dev after it diverged from 5.15.) Pick-to: 5.15 Change-Id: I3154ea1203e741cb337782d3374e02e15c5f209e Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Use QList instead of QVectorJarek Kobus2020-07-1513-31/+31
| | | | | | | | | | | | Task-number: QTBUG-84469 Change-Id: I666a060351f73783e15e3f96884c9393a5cd7e46 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Remove the unused include for QRegExpSona Kurazyan2020-07-151-1/+0
| | | | | | | | | | | | Task-number: QTBUG-85235 Change-Id: I2057e42e2b1ce4248f012b5e477120759d0ea805 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Adapt to newer dependenciesAllan Sandfeld Jensen2020-07-066-17/+25
| | | | | | | | | | | | Change-Id: I495880f56fbc10d8f332f26101f8a25c2a1c5631 Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io> Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* | Do not run offscreen test on macOSAllan Sandfeld Jensen2020-07-061-1/+1
| | | | | | | | | | | | | | Offscreen platform only supports OpenGL on Linux. Change-Id: Ibb13c741e9cb7de2baffd7a33bb812bce37d1c36 Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io>
* | Merge remote-tracking branch 'origin/5.15' into devAllan Sandfeld Jensen2020-06-296-18/+76
|\| | | | | | | | | | | | | Conflicts: src/src.pro Change-Id: I03c260ba676296f93d8137e79b46f3978f5f41ef
| * Add auto test for safe redirectTamas Zakor2020-06-101-0/+32
| | | | | | | | | | | | Task-number: QTBUG-84011 Change-Id: Ie1eef3bc850e99437bb02bea01e06a49029e0dc4 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| * Extend tst_QWebEngineScript::matchQrcUrl with negative matchJüri Valdmann2020-05-294-11/+26
| | | | | | | | | | Change-Id: Idee9e3742ea3cb949f786d0e55a2e2f8530c7b1e Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| * Fix 'qmake -r' runMichal Klocek2020-05-291-7/+18
| | | | | | | | | | | | | | Use current configure instead of qtHaveModule(). Change-Id: Ifc4500ff5eee4b997a0c02fb387d8918f88d06d1 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Merge "Merge remote-tracking branch 'origin/5.15' into dev"Allan Sandfeld Jensen2020-05-2813-48/+341
|\ \
| * | Merge remote-tracking branch 'origin/5.15' into devAllan Sandfeld Jensen2020-05-2813-48/+341
| |\| | | | | | | | | | Change-Id: I40d9ae90a4ea82c6242f5d0a1665af3856ad2f0b
| | * Fix resource paths in faviconbrowser manual testPeter Varga2020-05-271-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | It is necessary after e8284237 Enable most qmltests without testsupport Change-Id: Ib6668b852588b0a2afa911144a550b722db7f918 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| | * Test: port qwebenginedownloaditem auto test to QRegularExpressionPeter Varga2020-05-271-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | Leftover from cffba828 Test: port tests to QRegularExpression Task-number: QTBUG-72596 Change-Id: I4009bc00f24b773539a674ad5f2ba0aad1cef04b Reviewed-by: Samuel Gaist <samuel.gaist@idiap.ch>
| | * QML test case for certificate error handlingKirill Burtsev2020-05-265-2/+128
| | | | | | | | | | | | | | | Change-Id: I5609440666d41ea273f3be44fd860195750af4dd Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| | * Add test for first party urls of service workerTamas Zakor2020-05-264-0/+109
| | | | | | | | | | | | | | | Change-Id: Ic26d982ef9695705a9f7c757b7d983824b31a070 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| | * Remove leftover of tst_QWebEnginePage::inputFieldFocus auto testPeter Varga2020-05-251-14/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The test has been removed by: cfef4615 Delete QtWebKit tests from tst_qwebenginepage.cpp Pick-to: 5.15 Change-Id: I677772f00c99ae3b6e33a2d61c7135d4306d3674 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit 0891ac9c05b96471a0858011ef4f84b353337d16)
| | * Fix crash on WebContentsDelegateQt::CloseContents()Peter Varga2020-05-251-0/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | CloseContents() triggers a windowCloseRequested() signal. The handler of the signal might close the QWebEngineView and it would result the destruction of the WebContentsDelegateQt. Thus, any operation on WebContentsDelegateQt is not safe after a WebContentsAdapterClient::close() call. For example, calling QWebEngineView::close() on QWebEnginePage::windowCloseRequested() would result crash because it sets life cycle state to discarded which destructs web contents. Fixes: QTBUG-84355 Change-Id: I5da404bc9b1923cc19085ee899b550da49d1416b Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| | * Fix path validation in FilePickerController::accepted()Tamas Zakor2020-05-201-12/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In some cases QUrl::toLocalFile() does wrong path conversion on Windows. Therefore we have to convert the file URL to absolute path in another way and use FilePath::IsAbsolute() for validating that. Also stabilize WebEngineViewSingleFileUpload tests. They didn't wait for html title change when the expected value was the same as the default title. Change-Id: Ica7798a299f9b28657afeeccccfba3fdecc515e2 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| | * Allow to set feature permission before first ever navigationKirill Burtsev2020-05-141-24/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since PermissionManagerQt functions independent of webcontents initialization, permission installment may be done earlier (right after page base constructor). Practically, this allows to grant/deny permission before first ever navigation to avoid permission feature request from well-behaving web application. Unfortunately, this only applies to Web Notifications: there is a way to check without request: Notification.permission javascript static object. Other supported features lack similar mechanism: they operate through success/failure callbacks, which unconditionally invoke permission requests, and Page/View API doesn't automatically answer with remembered permissions. Task-number: QTBUG-83476 Change-Id: I63a3cbca25498d5026975073e125f2ab4f9ab2ad Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | | Add touchbrowser quick manual testPeter Varga2020-05-289-1/+703
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This browser is proposed to be used to test touch events on desktop without touch device. The fake touch events are generated on mouse events. The touch mocking is based on the qtwebbrowser implementation: http://code.qt.io/cgit/qt-apps/qtwebbrowser.git/ Task-number: QTBUG-59999 Change-Id: I5869020945bfae60db6f9e42de1b98d6239caa67 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | | Fix build of inputmethods manual testPeter Varga2020-05-281-1/+0
|/ / | | | | | | | | Change-Id: I013bc849fe44e9d8e15e1dc03a8e02ca5e71c559 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Remove leftover of tst_QWebEnginePage::inputFieldFocus auto testPeter Varga2020-05-201-14/+0
| | | | | | | | | | | | | | | | | | The test has been removed by: cfef4615 Delete QtWebKit tests from tst_qwebenginepage.cpp Pick-to: 5.15 Change-Id: I677772f00c99ae3b6e33a2d61c7135d4306d3674 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Merge remote-tracking branch 'origin/5.15' into devAllan Sandfeld Jensen2020-05-158-22/+327
|\| | | | | | | | | | | | | Conflicts: src/pdf/quick/qquickpdfselection_p.h Change-Id: I6eec37a01347c2d47cbfc1114326dfc6b58719ff
| * Fix setting WebEngineView.audioMuted before initializationJüri Valdmann2020-05-052-0/+64
| | | | | | | | | | | | Fixes: QTBUG-83732 Change-Id: Ie07a1ecf87b214436ab7cea07003ddd5aeaedda3 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| * Document early feature reply for NotificationAllan Sandfeld Jensen2020-05-051-0/+13
| | | | | | | | | | | | | | | | | | Make it easier to get right by normalizing the origin and test it. Task-number: QTBUG-83476 Change-Id: Ie4562e937cbcca5a1cf24e00d340a3ac2e9e2210 Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io> Reviewed-by: Kirill Burtsev <kirill.burtsev@qt.io>
| * Add cookie testcase to proxy testMichal Klocek2020-05-043-5/+55
| | | | | | | | | | | | Task-number: QTBUG-58121 Change-Id: I9953eaec9d4dd971a7f7fb3ed9a156bccffa05d5 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| * Merge remote-tracking branch 'origin/5.15.0' into 5.15Allan Sandfeld Jensen2020-04-302-5/+163
| |\ | | | | | | | | | Change-Id: I916838caf8c981d5dac876631a6e510ed2ffbe0e
| | * Restore behavior of OpenURLFromTab if createWindow returns thisJüri Valdmann2020-04-261-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of using QSharedPointer's reference count to communicate adoption/non-adoption, change adoptNewWindow to return a adapter pointer, with null meaning non-adoption. Then change QWebEnginePage's implementation to reuse already existing adapters if possible, restoring previous behavior of OpenURLFromTab when createWindow returns this. Task-number: QTBUG-80596 Change-Id: I8ee7c31e4294aabd3207c504cba67d6171c66cb0 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| | * Fix crash if createWindow returns this for AddNewContentsJüri Valdmann2020-04-261-0/+158
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For a QWebEnginePage subclass where createWindow returns the this-pointer, we get a crash in WebContentsDelegateQt::AddNewContents because AddNewContents expects the adapter to be adopted already, but QWebEnginePage delays adoption. Revert 3855015600 by getting rid of the delayed adoption code path. It's not needed anymore with the delayed initialization of the WebContentsAdapter. Revert 8a4091c210 by forcing adoption of the adapter even when it doesn't have contents. This no longer results in a crash since OpenURLFromTab ensures that the adapter is initialized before use. However, it does result in a behavior change since return-this now consistently overrides the adapter, so, e.g. navigation history is now always cleared whereas previously it was only cleared by the AddNewContents code path. Fixed with new approach in next patch. Fixes: QTBUG-80596 Change-Id: I4d2230c1bffcf2d77fa59ded9be51da49a820474 Reviewed-by: Kirill Burtsev <kirill.burtsev@qt.io>
| | * Fix flaky profile tests due to HTTP disconnectsJüri Valdmann2020-04-261-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | Resetting the network context can cause some (expected) disconnects, so return value of HttpServer::stop should be ignored. Fixes: QTBUG-83670 Change-Id: Ieb17b38c422f0cdaea5423d082fd04c22715cebe Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| * | Fix missing QWebEnginePage::audioMutedChanged signalJüri Valdmann2020-04-293-12/+32
| |/ | | | | | | | | Change-Id: Ie02da939a37575dd2b0a43440978748fd79874e4 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Merge remote-tracking branch 'origin/5.15' into devAllan Sandfeld Jensen2020-04-2772-136/+513
|\| | | | | | | | | | | | | | | Conflicts: configure.pri src/pdf/api/qpdfpagerenderer.h Change-Id: I7e68277080e29238bbfe8511539ea75b2db89489
| * Move request interceptor to ui threadMichal Klocek2020-04-201-27/+96
| | | | | | | | | | | | | | | | | | | | | | | | | | We use now network service avoid io-ui-io-ui hops, pipe proxying url loader factory directly to ui thread. This solves thread safty issues. Add deprecated request interceptor test cases. Task-number: QTBUG-83082 Task-number: QTBUG-82999 Change-Id: I38778cf1a70789c5e92e04c93d1c93e2cc4c765a Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| * Stabilize widget auto tests which use evaluateJavaScriptSync()Peter Varga2020-04-091-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Interrupt the waiting on the event loop in CallbackSpy::waitForResult() to not block calls on the UI thread. It is necessary because RenderProcessHost creates channel for mojo communication on the UI thread. QWebEnginePage::runJavaScript() needs this channel because the JavaScript is executed in the render process. If evaluateJavaScriptSync() is called before the mentioned channel is created, the JavaScriptExecuteRequest mojo message might not be sent because the wait would block the thread. Change-Id: Ic5bb5a6fde02717cec49dcf9e458f2eaac09eacf Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| * Test qquickwebengineview: remove unneeded blacklistingKirill Burtsev2020-04-091-3/+0
| | | | | | | | | | | | | | | | As the dependency 6420ad91d3 in declarative for the only present focusChild is integrated and test doesn't fail according to grafana. Change-Id: I0d8fbb966548687d3fb92ec123726f110f18d8d5 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
| * Use SetBaseBackgroundColorOverride for setting background colorJüri Valdmann2020-04-091-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | The normal WebViewImpl::SetBaseBackgroundColor expects to be called only during certain lifecycle states, otherwise a DCHECK will be triggered. Whereas the *Override version forces a lifecycle update. Needs 3rdparty change to stop RenderWidgetHostViewBase::SetBaseBackgroundColor from clearing the override color when switching between opaque and transparent colors though. Change-Id: If4c1e22886d7ebc7d87ca880dd9c6a659855a931 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
| * Enable most qmltests without testsupportAllan Sandfeld Jensen2020-04-0757-67/+313
| | | | | | | | | | | | | | | | | | Move the qmltests that require testsupport to qmltests2, this enables us to run most of the tests on CI configurations that isn't developer- builds. Change-Id: Ie0ba060632b36cbd738d6ede512a6a5f35880ae3 Reviewed-by: Michal Klocek <michal.klocek@qt.io>
| * Adaptations for Chromium 80Allan Sandfeld Jensen2020-04-072-10/+12
| | | | | | | | | | Change-Id: Icaf68648cbc2c13a61fc3b208ff1e64ca36c90b6 Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io>
| * Fix flaky tst_QWebEngineProfile::clearDataFromCacheJüri Valdmann2020-04-031-0/+3
| | | | | | | | | | | | Fixes: QTBUG-82953 Change-Id: I7dfa916ea0ada00ce84a1e9e49de9eea1800a108 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
| * Speculative fix for titleUpdate test caseMichal Klocek2020-04-022-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | After tedious investigation the issue boils down to error prone synchronization of web engine settings. WebEngineSettings are synchronized between the browser process and the render process. Moreover in the browser process the sync message is send to the render with QTimer::singleShot, which can cause race conditions if for example QWebPage::setUrl was used meanwhile. This makes current settings not being picked up by the render process and results in 'titleUpdate' test case flaky. This happens due to the fact that ShouldDisplayErrorPageForFailedLoad in the render process frame view could have invalid value. Try to sync web engine settings on every adapter load, setContent or reload. Mark some flaky settings in tests. Fixes: QTBUG-83078 Change-Id: I5289472f146e104d5cb6c3b9b20b26d3dc42f4b1 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| * Merge "Merge branch '5.14' into 5.15"v5.15.0-beta3Allan Sandfeld Jensen2020-03-312-8/+38
| |\
| | * Merge branch '5.14' into 5.15Allan Sandfeld Jensen2020-03-262-8/+38
| | |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/3rdparty tests/auto/widgets/qwebenginepage/tst_qwebenginepage.cpp Change-Id: Idbc9d3b06c0052a721c974fbcbfa3164faaead14
| | | * Merge remote-tracking branch 'origin/5.14.2' into 5.14Allan Sandfeld Jensen2020-03-251-0/+38
| | | |\ | | | | | | | | | | | | | | | Change-Id: I5f7aab6031f1c1ca289d5ba408d408684849031c
| | | | * Merge 5.14 into 5.14.2Kari Oikarinen2020-03-103-21/+18
| | | | |\ | | | | | | | | | | | | | | | | | | Change-Id: I50afabc6022fea5b3db2a7dcb8659b654573661f
| | | | * | Fix applying background color on RenderViewPeter Varga2020-03-101-0/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The RenderViewObserverQt_SetBackgroundColor message was sent with wrong Routing ID. This fix also cleans up RenderWidgetHostViewQt::UpdateBackgroundColor() method. Fixes: QTBUG-81781 Change-Id: Ida198fb061715d389859ace17e1f773db491c51d Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io>