diff options
| author | Tarja Sundqvist <tarja.sundqvist@qt.io> | 2024-10-07 17:38:05 +0300 |
|---|---|---|
| committer | Tarja Sundqvist <tarja.sundqvist@qt.io> | 2024-10-07 17:44:32 +0300 |
| commit | 183d0101f41fd5a1007708a9416d1f12db31c1cb (patch) | |
| tree | 969a5e91aef3b4c6805331e56c24fa6be8738f6b /tests/auto/widgets/proxy/tst_proxy.cpp | |
| parent | 17e9f29577ea6573c7c348083ff510ee60c7e8cc (diff) | |
| parent | 13381ca9e80578d038835c8a4dc609d75dfdec4c (diff) | |
Merge tag 'v6.2.10-lts' into tqtc/lts-6.2-opensourcev6.2.10-lts-lgpl6.2.10
Qt 6.2.10-lts release
Conflicts solved:
CHROMIUM_VERSION
dependencies.yaml
src/core/web_engine_context.cpp
Change-Id: Ia54316ba0df3488d8e13c8f14fead1d90099519b
Diffstat (limited to 'tests/auto/widgets/proxy/tst_proxy.cpp')
| -rw-r--r-- | tests/auto/widgets/proxy/tst_proxy.cpp | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/tests/auto/widgets/proxy/tst_proxy.cpp b/tests/auto/widgets/proxy/tst_proxy.cpp index f378ae22f..3dc72618c 100644 --- a/tests/auto/widgets/proxy/tst_proxy.cpp +++ b/tests/auto/widgets/proxy/tst_proxy.cpp @@ -8,7 +8,7 @@ #include <QWebEnginePage> #include <QWebEngineView> #include <QWebEngineUrlRequestInterceptor> - +#include <QWebEngineLoadingInfo> struct Interceptor : public QWebEngineUrlRequestInterceptor { @@ -28,6 +28,7 @@ public: private slots: void proxyAuthentication(); void forwardCookie(); + void invalidHostName(); }; @@ -72,6 +73,19 @@ void tst_Proxy::forwardCookie() QTRY_VERIFY2(cookieSpy.size() > 0, "Could not get cookie"); } +// Crash test ( https://bugreports.qt.io/browse/QTBUG-113992 ) +void tst_Proxy::invalidHostName() +{ + QNetworkProxy proxy; + proxy.setType(QNetworkProxy::HttpProxy); + proxy.setHostName("999.0.0.0"); + QNetworkProxy::setApplicationProxy(proxy); + QWebEnginePage page; + QSignalSpy loadSpy(&page, SIGNAL(loadFinished(bool))); + page.load(QUrl("http://www.qt.io")); + QTRY_COMPARE_WITH_TIMEOUT(loadSpy.size(), 1, 20000); +} + #include "tst_proxy.moc" QTEST_MAIN(tst_Proxy) |
