Commit f3b40712 authored by Dan Fandrich's avatar Dan Fandrich
Browse files

Added test of IPv6 scope handling

parent fe1d0243
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -54,7 +54,8 @@ EXTRA_DIST = test1 test108 test117 test127 test20 test27 test34 test46 \
 test556 test1031 test628 test629 test630 test631 test632 test1032         \
 test1033 test539 test1034 test1035 test1036 test1037 test1038 test1039    \
 test1040 test1041 test1042 test1043 test1044 test1045 test1046 test1047   \
 test1048 test1049 test1050 test1051 test1052 test1053 test1054 test1055
 test1048 test1049 test1050 test1051 test1052 test1053 test1054 test1055   \
 test1056

filecheck:
	@mkdir test-place; \

tests/data/test1056

0 → 100644
+81 −0
Original line number Diff line number Diff line
<testcase>
<info>
<keywords>
HTTP
HTTP GET
followlocation
IPv6
</keywords>
</info>

#
# Server-side
<reply>
<data>
HTTP/1.1 302 OK swsclose
Location: http://[::1%259999]:8994/moo/10560002
Date: Thu, 31 Jul 2008 14:49:00 GMT
Connection: close

</data>
<data2>
HTTP/1.1 200 OK swsclose
Date: Thu, 31 Jul 2008 14:49:00 GMT
Connection: close

body
</data2>
<datacheck>
HTTP/1.1 302 OK swsclose
Location: http://[::1%259999]:8994/moo/10560002
Date: Thu, 31 Jul 2008 14:49:00 GMT
Connection: close

HTTP/1.1 200 OK swsclose
Date: Thu, 31 Jul 2008 14:49:00 GMT
Connection: close

body
</datacheck>
</reply>

#
# Client-side
<client>
<features>
ipv6
</features>
<server>
http
http-ipv6
</server>
 <name>
HTTP follow redirect from IPv4 to IPv6 with scope
 </name>
 <command>
http://%HOSTIP:%HTTPPORT/we/are/all/twits/1056 -L
</command>
# The data section doesn't do variable substitution, so we must assert this
<precheck>
perl -e "print 'Test requires default test server host and port' if ( '%HOST6IP' ne '[::1]' || '%HTTP6PORT' ne '8994' );"
</precheck>
</client>

#
# Verify data after the test has been "shot"
<verify>
<strip>
^User-Agent:.*
</strip>
<protocol>
GET /we/are/all/twits/1056 HTTP/1.1
Host: %HOSTIP:%HTTPPORT
Accept: */*

GET /moo/10560002 HTTP/1.1
Host: %HOST6IP:%HTTP6PORT
Accept: */*

</protocol>
</verify>
</testcase>