f1f1a3ceb62ec5fbebe5a502d0ac9359dd18869c
[platform/upstream/curl.git] / tests / data / test510
1 <testcase>
2 <info>
3 <keywords>
4 HTTP
5 HTTP POST
6 </keywords>
7 </info>
8
9 #
10 # Server-side
11 <reply>
12 <data mode="text">
13 HTTP/1.1 200 OK
14 Date: Thu, 09 Nov 2010 14:49:00 GMT
15 Server: test-server/fake swsclose
16 Connection: close
17 Content-Type: text/html
18
19 hello
20 </data>
21 </reply>
22
23 # Client-side
24 <client>
25 <server>
26 http
27 </server>
28 # tool is what to use instead of 'curl'
29 <tool>
30 lib510
31 </tool>
32
33  <name>
34 send HTTP POST using read callback, using chunked transfer-encoding
35  </name>
36  <command>
37 http://%HOSTIP:%HTTPPORT/510
38 </command>
39 </client>
40
41 #
42 # Verify data after the test has been "shot"
43 <verify>
44 <protocol>
45 POST /510 HTTP/1.1\r
46 Host: %HOSTIP:%HTTPPORT\r
47 Accept: */*\r
48 Transfer-Encoding: chunked\r
49 Content-Type: application/x-www-form-urlencoded\r
50 Expect: 100-continue\r
51 \r
52 3\r
53 one\r
54 3\r
55 two\r
56 5\r
57 three\r
58 1d\r
59 and a final longer crap: four\r
60 0\r
61 \r
62 </protocol>
63 </verify>
64 </testcase>