1<testcase> 2<info> 3<keywords> 4HTTP 5HTTP POST 6followlocation 7</keywords> 8</info> 9 10# 11# Server-side 12<reply> 13<data> 14HTTP/1.1 301 OK swsclose 15Location: moo/testcase/10540002 16Date: Thu, 31 Jul 2008 14:49:00 GMT 17Connection: close 18 19</data> 20<data2> 21HTTP/1.1 200 OK swsclose 22Date: Thu, 31 Jul 2008 14:49:00 GMT 23Connection: close 24 25body 26</data2> 27<datacheck> 28HTTP/1.1 301 OK swsclose 29Location: moo/testcase/10540002 30Date: Thu, 31 Jul 2008 14:49:00 GMT 31Connection: close 32 33HTTP/1.1 200 OK swsclose 34Date: Thu, 31 Jul 2008 14:49:00 GMT 35Connection: close 36 37body 38</datacheck> 39</reply> 40 41# 42# Client-side 43<client> 44<server> 45http 46</server> 47 <name> 48HTTP POST from file with 301 redirect and --post301 49 </name> 50<file name="log/test1054.txt"> 51field=data 52</file> 53 <command> 54http://%HOSTIP:%HTTPPORT/blah/1054 -L -d @log/test1054.txt --post301 55</command> 56</client> 57 58# 59# Verify data after the test has been "shot" 60<verify> 61<strip> 62^User-Agent:.* 63</strip> 64<protocol nonewline="yes"> 65POST /blah/1054 HTTP/1.1 66Host: %HOSTIP:%HTTPPORT 67Accept: */* 68Content-Length: 10 69Content-Type: application/x-www-form-urlencoded 70 71field=dataPOST /blah/moo/testcase/10540002 HTTP/1.1 72Host: %HOSTIP:%HTTPPORT 73Accept: */* 74Content-Length: 10 75Content-Type: application/x-www-form-urlencoded 76 77field=data 78</protocol> 79</verify> 80</testcase> 81