2007-01-22 21:25:56 -05:00
|
|
|
<testcase>
|
2003-10-07 10:43:48 -04:00
|
|
|
#
|
|
|
|
# Server-side
|
|
|
|
<reply>
|
2005-06-03 10:06:03 -04:00
|
|
|
<data mode="text">
|
2003-10-07 10:43:48 -04:00
|
|
|
HTTP/1.1 200 OK
|
|
|
|
Date: Thu, 09 Nov 2010 14:49:00 GMT
|
|
|
|
Server: test-server/fake swsclose
|
|
|
|
Connection: close
|
|
|
|
Content-Type: text/html
|
|
|
|
|
|
|
|
hello
|
|
|
|
</data>
|
|
|
|
</reply>
|
|
|
|
|
|
|
|
# Client-side
|
|
|
|
<client>
|
|
|
|
<server>
|
|
|
|
http
|
|
|
|
</server>
|
|
|
|
# tool is what to use instead of 'curl'
|
|
|
|
<tool>
|
|
|
|
lib508
|
|
|
|
</tool>
|
|
|
|
|
|
|
|
<name>
|
|
|
|
send HTTP POST using read callback
|
|
|
|
</name>
|
|
|
|
<command>
|
2004-09-08 04:08:38 -04:00
|
|
|
http://%HOSTIP:%HTTPPORT/508
|
2003-10-07 10:43:48 -04:00
|
|
|
</command>
|
|
|
|
</client>
|
|
|
|
|
|
|
|
#
|
|
|
|
# Verify data after the test has been "shot"
|
|
|
|
<verify>
|
2009-05-11 13:21:26 -04:00
|
|
|
<strippart>
|
|
|
|
# remove CR that CURLOPT_TRANSFERTEXT added, when CharConv enabled:
|
|
|
|
s/^(this is what we post to the silly web server)\r\n/$1\n/ if($has_charconv)
|
|
|
|
</strippart>
|
2003-10-07 10:43:48 -04:00
|
|
|
<protocol>
|
|
|
|
POST /508 HTTP/1.1
|
2007-09-14 15:32:31 -04:00
|
|
|
Host: %HOSTIP:%HTTPPORT
|
2004-02-09 07:46:41 -05:00
|
|
|
Accept: */*
|
2003-10-07 10:43:48 -04:00
|
|
|
Content-Length: 45
|
|
|
|
Content-Type: application/x-www-form-urlencoded
|
|
|
|
|
|
|
|
this is what we post to the silly web server
|
|
|
|
</protocol>
|
|
|
|
</verify>
|
2007-01-22 21:25:56 -05:00
|
|
|
</testcase>
|