Debian Codegraph @

curl/tests/data/test43

raw
1 <info>
2 <keywords>
3 HTTP
4 HTTP GET
5 followlocation
6 HTTP proxy
7 </keywords>
8 </info>
9 # Server-side
10 <reply>
11 <data>
12 HTTP/1.1 301 This is a weirdo text message
13 Date: Thu, 09 Nov 2010 14:49:00 GMT
14 Server: test-server/fake
15 Location: data/430002.txt?coolsite=yes
16 Connection: close
17
18 This server reply is for testing a simple Location: following
19
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
26 If this is received, the location following worked
27
28 </data2>
29 <datacheck>
30 HTTP/1.1 301 This is a weirdo text message
31 Date: Thu, 09 Nov 2010 14:49:00 GMT
32 Server: test-server/fake
33 Location: data/430002.txt?coolsite=yes
34 Connection: close
35
36 HTTP/1.1 200 Followed here fine swsclose
37 Date: Thu, 09 Nov 2010 14:49:00 GMT
38 Server: test-server/fake
39
40 If this is received, the location following worked
41
42 </datacheck>
43 </reply>
44
45 # Client-side
46 <client>
47 <server>
48 http
49 </server>
50 <name>
51 HTTP Location: following over HTTP proxy
52 </name>
53 <command>
54 http://%HOSTIP:%HTTPPORT/want/43 -L -x %HOSTIP:%HTTPPORT
55 </command>
56 </client>
57
58 # Verify data after the test has been "shot"
59 <verify>
60 <strip>
61 ^User-Agent:.*
62 </strip>
63 <protocol>
64 GET http://127.0.0.1:%HTTPPORT/want/43 HTTP/1.1
65 Host: 127.0.0.1:%HTTPPORT
66 Pragma: no-cache
67 Accept: */*
68 Proxy-Connection: Keep-Alive
69
70 GET http://127.0.0.1:%HTTPPORT/want/data/430002.txt?coolsite=yes HTTP/1.1
71 Host: 127.0.0.1:%HTTPPORT
72 Pragma: no-cache
73 Accept: */*
74 Proxy-Connection: Keep-Alive
75
76 </protocol>
77 </verify>