1<testcase> 2<info> 3<keywords> 4HTTP 5HTTP proxy 6followlocation 7cookies 8</keywords> 9</info> 10# 11# Server-side 12<reply> 13<data> 14HTTP/1.1 302 OK 15Date: Tue, 09 Nov 2010 14:49:00 GMT 16Server: test-server/fake swsclose 17Content-Type: text/html 18Funny-head: yesyes 19Location: http://goto.second.host.now/%TESTNUMBER0002 20Content-Length: 8 21Connection: close 22 23contents 24</data> 25<data2> 26HTTP/1.1 200 OK 27Date: Tue, 09 Nov 2010 14:49:00 GMT 28Server: test-server/fake swsclose 29Content-Type: text/html 30Funny-head: yesyes 31Content-Length: 9 32 33contents 34</data2> 35 36<datacheck> 37HTTP/1.1 302 OK 38Date: Tue, 09 Nov 2010 14:49:00 GMT 39Server: test-server/fake swsclose 40Content-Type: text/html 41Funny-head: yesyes 42Location: http://goto.second.host.now/%TESTNUMBER0002 43Content-Length: 8 44Connection: close 45 46HTTP/1.1 200 OK 47Date: Tue, 09 Nov 2010 14:49:00 GMT 48Server: test-server/fake swsclose 49Content-Type: text/html 50Funny-head: yesyes 51Content-Length: 9 52 53contents 54</datacheck> 55</reply> 56 57# 58# Client-side 59<client> 60<server> 61http 62</server> 63<name> 64HTTP with custom Cookie: and redirect to new host 65</name> 66<command> 67http://first.host.it.is/we/want/that/page/%TESTNUMBER -x %HOSTIP:%HTTPPORT -H "Cookie: test=yes" --location 68</command> 69<features> 70proxy 71</features> 72</client> 73 74# 75# Verify data after the test has been "shot" 76<verify> 77<protocol> 78GET http://first.host.it.is/we/want/that/page/%TESTNUMBER HTTP/1.1 79Host: first.host.it.is 80User-Agent: curl/%VERSION 81Accept: */* 82Proxy-Connection: Keep-Alive 83Cookie: test=yes 84 85GET http://goto.second.host.now/%TESTNUMBER0002 HTTP/1.1 86Host: goto.second.host.now 87User-Agent: curl/%VERSION 88Accept: */* 89Proxy-Connection: Keep-Alive 90 91</protocol> 92</verify> 93</testcase> 94