diff options
author | Liang Qi <liang.qi@qt.io> | 2017-09-20 11:37:26 +0200 |
---|---|---|
committer | Liang Qi <liang.qi@qt.io> | 2017-09-20 11:58:32 +0200 |
commit | 01bc69f99f189b03d0b9cad77cc300798937cad1 (patch) | |
tree | 730f3b691cfc1830ec617b3c2ad8df16180de724 /tests/auto/network/access/qnetworkreply/tst_qnetworkreply.cpp | |
parent | c23c4a921d0e9e2d18a62af82d38ca27eac7bcb3 (diff) | |
parent | 6d699d08200b1fe3a616dfbc275d46c98b77fcbd (diff) |
Merge remote-tracking branch 'origin/5.9' into 5.10
Conflicts:
src/plugins/styles/mac/qmacstyle_mac.mm
src/widgets/util/qcompleter.cpp
src/widgets/widgets/qmainwindowlayout.cpp
src/widgets/widgets/qmdisubwindow.cpp
Change-Id: If0e96981af07ce36ac68f2e69211bc2120f93973
Diffstat (limited to 'tests/auto/network/access/qnetworkreply/tst_qnetworkreply.cpp')
-rw-r--r-- | tests/auto/network/access/qnetworkreply/tst_qnetworkreply.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/auto/network/access/qnetworkreply/tst_qnetworkreply.cpp b/tests/auto/network/access/qnetworkreply/tst_qnetworkreply.cpp index 855b1f9041..e995b69f60 100644 --- a/tests/auto/network/access/qnetworkreply/tst_qnetworkreply.cpp +++ b/tests/auto/network/access/qnetworkreply/tst_qnetworkreply.cpp @@ -5773,6 +5773,15 @@ void tst_QNetworkReply::proxyChange() QNetworkRequest req(QUrl("http://" + QtNetworkSettings::serverName())); proxyServer.doClose = false; + { + // Needed to initialize a network session in QNAM. Without an initialized session the GET + // will be deferred until later, and the proxy will be unset first. This caused the test to + // fail in standalone runs (it passed in CI because the same QNAM instance is used for the + // entire test). + QNetworkReplyPtr temporary(manager.get(req)); + waitForFinish(temporary); + } + manager.setProxy(dummyProxy); QNetworkReplyPtr reply1(manager.get(req)); connect(reply1, SIGNAL(finished()), &helper, SLOT(finishedSlot())); |