Git init
[external/curl.git] / tests / data / test2001
1 <testcase>
2 <info>
3 <keywords>
4 HTTP
5 HTTP GET
6 FTP
7 PASV
8 FILE
9 multiprotocol
10 </keywords>
11 </info>
12
13 #
14 # Server-side
15 <reply>
16 <data1 nocheck="yes">
17 HTTP/1.1 200 OK\r
18 Date: Thu, 09 Nov 2010 14:49:00 GMT\r
19 Server: test-server/fake\r
20 Last-Modified: Tue, 13 Jun 2000 12:10:00 GMT\r
21 ETag: "21025-dc7-39462498"\r
22 Accept-Ranges: bytes\r
23 Content-Length: 6\r
24 Connection: close\r
25 Content-Type: text/html\r
26 Funny-head: yesyes\r
27 \r
28 -foo-
29 </data1>
30 <data2 nocheck="yes">
31 data
32     to
33       see
34 that FTP
35 works
36   so does it?
37 </data2>
38 </reply>
39
40 #
41 # Client-side
42 <client>
43 <server>
44 http
45 ftp
46 file
47 </server>
48  <name>
49 HTTP GET followed by FTP RETR followed by FILE
50  </name>
51  <command>
52 http://%HOSTIP:%HTTPPORT/20010001 ftp://%HOSTIP:%FTPPORT/20010002 file://localhost/%PWD/log/test2001.txt
53 </command>
54 <file name="log/test2001.txt">
55 foo
56    bar
57 bar
58    foo
59 moo
60 </file>
61 </client>
62
63 #
64 # Verify data after the test has been "shot"
65 <verify>
66 <strip>
67 ^User-Agent:.*
68 </strip>
69 <protocol>
70 GET /20010001 HTTP/1.1\r
71 Host: %HOSTIP:%HTTPPORT\r
72 Accept: */*\r
73 \r
74 USER anonymous\r
75 PASS ftp@example.com\r
76 PWD\r
77 EPSV\r
78 TYPE I\r
79 SIZE 20010002\r
80 RETR 20010002\r
81 QUIT\r
82 </protocol>
83 <stdout>
84 HTTP/1.1 200 OK\r
85 Date: Thu, 09 Nov 2010 14:49:00 GMT\r
86 Server: test-server/fake\r
87 Last-Modified: Tue, 13 Jun 2000 12:10:00 GMT\r
88 ETag: "21025-dc7-39462498"\r
89 Accept-Ranges: bytes\r
90 Content-Length: 6\r
91 Connection: close\r
92 Content-Type: text/html\r
93 Funny-head: yesyes\r
94 \r
95 -foo-
96 data
97     to
98       see
99 that FTP
100 works
101   so does it?
102 foo
103    bar
104 bar
105    foo
106 moo
107 </stdout>
108 </verify>
109 </testcase>