Resync
[CMakeLuaTailorHgBridge.git] / CMakeLua / Utilities / cmcurl-7.19.0 / tests / data / test276
blob7d7f7439634998fbf5f891aff746c2081dea20a6
1 <testcase>
2 <info>
3 <keywords>
4 HTTP
5 HTTP GET
6 followlocation
7 </keywords>
8 </info>
9 # Server-side
10 <reply>
11 <data>
12 HTTP/1.1 301 This is a weirdo text message swsclose
13 Date: Thu, 09 Nov 2010 14:49:00 GMT
14 Server: test-server/fake
15 Location: data/2760002.txt?coolsite=http://anotherurl/?a_second/2760002
16 Connection: close
18 This server reply is for testing a simple Location: following
20 </data>
21 <data2>
22 HTTP/1.1 200 Followed here fine swsclose
23 Date: Thu, 09 Nov 2010 14:49:00 GMT
24 Server: test-server/fake
25 Content-Length: 52
27 If this is received, the location following worked
29 </data2>
30 <datacheck>
31 HTTP/1.1 301 This is a weirdo text message swsclose
32 Date: Thu, 09 Nov 2010 14:49:00 GMT
33 Server: test-server/fake
34 Location: data/2760002.txt?coolsite=http://anotherurl/?a_second/2760002
35 Connection: close
37 HTTP/1.1 200 Followed here fine swsclose
38 Date: Thu, 09 Nov 2010 14:49:00 GMT
39 Server: test-server/fake
40 Content-Length: 52
42 If this is received, the location following worked
44 </datacheck>
45 </reply>
47 # Client-side
48 <client>
49 <server>
50 http
51 </server>
52  <name>
53 HTTP Location: following with multiple question marks in URLs
54  </name>
55  <command>
56 "http://%HOSTIP:%HTTPPORT/want?uri=http://anything/276?secondq/276" -L
57 </command>
58 </client>
60 # Verify data after the test has been "shot"
61 <verify>
62 <strip>
63 ^User-Agent:.*
64 </strip>
65 <protocol>
66 GET /want?uri=http://anything/276?secondq/276 HTTP/1.1
67 Host: %HOSTIP:%HTTPPORT
68 Accept: */*
70 GET /data/2760002.txt?coolsite=http://anotherurl/?a_second/2760002 HTTP/1.1
71 Host: %HOSTIP:%HTTPPORT
72 Accept: */*
74 </protocol>
75 </verify>
76 </testcase>