test1134: verify CREDSPERREQUEST for HTTP
authorDaniel Stenberg <daniel@haxx.se>
Sun, 18 May 2014 14:55:03 +0000 (16:55 +0200)
committerDaniel Stenberg <daniel@haxx.se>
Sun, 18 May 2014 14:55:03 +0000 (16:55 +0200)
Verifies that the change in 68f0166a92 works as intended and that
different HTTP auth credentials to the same host still re-uses the
connection properly.

tests/data/Makefile.am
tests/data/test1134 [new file with mode: 0644]

index 98aaee0..0a767b3 100644 (file)
@@ -97,7 +97,7 @@ test1096 test1097 test1098 test1099 test1100 test1101 test1102 test1103 \
 test1104 test1105 test1106 test1107 test1108 test1109 test1110 test1111 \
 test1112 test1113 test1114 test1115 test1116 test1117 test1118 test1119 \
 test1120 test1121 test1122 test1123 test1124 test1125 test1126 test1127 \
-test1128 test1129 test1130 test1131 test1132 test1133 \
+test1128 test1129 test1130 test1131 test1132 test1133 test1134 \
 \
 test1200 test1201 test1202 test1203 test1204 test1205 test1206 test1207 \
 test1208 test1209 test1210 test1211 test1212 test1213 test1214 test1215 \
diff --git a/tests/data/test1134 b/tests/data/test1134
new file mode 100644 (file)
index 0000000..f8db6eb
--- /dev/null
@@ -0,0 +1,65 @@
+<testcase>
+<info>
+<keywords>
+HTTP
+HTTP HEAD
+-G
+</keywords>
+</info>
+#
+# Server-side
+<reply>
+<servercmd>
+connection-monitor
+</servercmd>
+<data>
+HTTP/1.1 200 OK
+Date: Thu, 09 Nov 2010 14:49:00 GMT
+Content-Length: 10
+
+contents1
+</data>
+<data1>
+HTTP/1.1 200 OK
+Date: Thu, 09 Nov 2010 14:49:00 GMT
+Content-Length: 10
+
+contents2
+</data1>
+</reply>
+
+#
+# Client-side
+<client>
+<server>
+http
+</server>
+ <name>
+HTTP connection re-use with different credentials
+ </name>
+ <command>
+http://%HOSTIP:%HTTPPORT/1134 -u user1:password1 --next http://%HOSTIP:%HTTPPORT/11340001 -u 2user:password2
+</command>
+</client>
+
+#
+# Verify data after the test has been "shot"
+<verify>
+<strip>
+^User-Agent:.*
+</strip>
+<protocol>
+GET /1134 HTTP/1.1\r
+Authorization: Basic dXNlcjE6cGFzc3dvcmQx\r
+Host: %HOSTIP:%HTTPPORT\r
+Accept: */*\r
+\r
+GET /11340001 HTTP/1.1\r
+Authorization: Basic MnVzZXI6cGFzc3dvcmQy\r
+Host: %HOSTIP:%HTTPPORT\r
+Accept: */*\r
+\r
+[DISCONNECT]
+</protocol>
+</verify>
+</testcase>