summaryrefslogtreecommitdiffstats
path: root/tests/auto/qhttpnetworkconnection
diff options
context:
space:
mode:
authorMarkus Goetz <Markus.Goetz@nokia.com>2010-01-11 16:58:52 (GMT)
committerMarkus Goetz <Markus.Goetz@nokia.com>2010-01-11 16:58:52 (GMT)
commit1b1aab443117f818914ed2434a5ea7a1002d4cc9 (patch)
treec7b27b14aef7fa5ec710c847a631259ccf5cdc50 /tests/auto/qhttpnetworkconnection
parentc69b85ebf532bf7daf0644f4b3d0b2a6c19ace1d (diff)
downloadQt-1b1aab443117f818914ed2434a5ea7a1002d4cc9.zip
Qt-1b1aab443117f818914ed2434a5ea7a1002d4cc9.tar.gz
Qt-1b1aab443117f818914ed2434a5ea7a1002d4cc9.tar.bz2
tst_qhttpnetworkconnection: Test also HEAD in some tests
Reviewed-by: TrustMe
Diffstat (limited to 'tests/auto/qhttpnetworkconnection')
-rw-r--r--tests/auto/qhttpnetworkconnection/tst_qhttpnetworkconnection.cpp13
1 files changed, 10 insertions, 3 deletions
diff --git a/tests/auto/qhttpnetworkconnection/tst_qhttpnetworkconnection.cpp b/tests/auto/qhttpnetworkconnection/tst_qhttpnetworkconnection.cpp
index cafbc2c..f27f469 100644
--- a/tests/auto/qhttpnetworkconnection/tst_qhttpnetworkconnection.cpp
+++ b/tests/auto/qhttpnetworkconnection/tst_qhttpnetworkconnection.cpp
@@ -866,8 +866,11 @@ void tst_QHttpNetworkConnection::getMultipleWithPipeliningAndMultiplePriorities(
QList<QHttpNetworkReply*> replies;
for (int i = 0; i < requestCount; i++) {
-
- QHttpNetworkRequest *request = new QHttpNetworkRequest("http://" + QtNetworkSettings::serverName() + "/qtest/rfc3252.txt");
+ QHttpNetworkRequest *request = 0;
+ if (i % 3)
+ request = new QHttpNetworkRequest("http://" + QtNetworkSettings::serverName() + "/qtest/rfc3252.txt", QHttpNetworkRequest::Get);
+ else
+ request = new QHttpNetworkRequest("http://" + QtNetworkSettings::serverName() + "/qtest/rfc3252.txt", QHttpNetworkRequest::Head);
if (i % 2 || i % 3)
request->setPipeliningAllowed(true);
@@ -957,7 +960,11 @@ void tst_QHttpNetworkConnection::getMultipleWithPriorities()
QList<QHttpNetworkReply*> replies;
for (int i = 0; i < requestCount; i++) {
- QHttpNetworkRequest *request = new QHttpNetworkRequest(url);;
+ QHttpNetworkRequest *request = 0;
+ if (i % 3)
+ request = new QHttpNetworkRequest(url, QHttpNetworkRequest::Get);
+ else
+ request = new QHttpNetworkRequest(url, QHttpNetworkRequest::Head);
if (i % 2)
request->setPriority(QHttpNetworkRequest::HighPriority);