Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make sure to set LANG variable before running tests #1279

Closed
wants to merge 5 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
101 changes: 51 additions & 50 deletions tests/data/test1035
Original file line number Diff line number Diff line change
@@ -1,59 +1,60 @@
<testcase>
<info>
<keywords>
HTTP
HTTP GET
HTTP proxy
IDN
FAILURE
</keywords>
</info>

#
# Server-side
<reply>
<data>
<testcase>
<info>
<keywords>
HTTP
HTTP GET
HTTP proxy
IDN
FAILURE
</keywords>
</info>
#
# Server-side
<reply>
<data>
HTTP/1.0 503 Service Unavailable
Date: Thu, 09 Nov 2010 14:49:00 GMT
Server: test-server/fake swsclose
Content-Type: text/html
Funny-head: yesyes

</data>
</reply>

#
# Client-side
<client>
<server>
http
</server>
<features>
idn
</features>
<setenv>
CHARSET=ISO8859-1
</setenv>
<name>
HTTP over proxy with too long IDN host name
</name>
<command>
http://too-long-IDN-name-c�rl-r�les-la-la-la-dee-da-flooby-nooby.local/page/1035 -x %HOSTIP:%HTTPPORT
</command>
</client>

#
# Verify data after the test has been "shot"
<verify>
<strip>
^User-Agent:.*
</strip>
<protocol>
GET http://too-long-IDN-name-c�rl-r�les-la-la-la-dee-da-flooby-nooby.local/page/1035 HTTP/1.1
Host: too-long-IDN-name-c�rl-r�les-la-la-la-dee-da-flooby-nooby.local
</data>
</reply>

#
# Client-side
<client>
<server>
http
</server>
<features>
idn
</features>
<setenv>
CHARSET=UTF-8
LANG=en_US.UTF-8
</setenv>
<name>
HTTP over proxy with too long IDN host name
</name>
<command>
http://too-long-IDN-name-cürl-rüles-la-la-la-dee-da-flooby-nooby.local/page/1035 -x %HOSTIP:%HTTPPORT
</command>
</client>

#
# Verify data after the test has been "shot"
<verify>
<strip>
^User-Agent:.*
</strip>
<protocol>
GET http://too-long-IDN-name-cürl-rüles-la-la-la-dee-da-flooby-nooby.local/page/1035 HTTP/1.1
Host: too-long-IDN-name-cürl-rüles-la-la-la-dee-da-flooby-nooby.local
Accept: */*
Proxy-Connection: Keep-Alive

</protocol>
</verify>
</testcase>
</protocol>
</verify>
</testcase>
173 changes: 87 additions & 86 deletions tests/data/test2046
Original file line number Diff line number Diff line change
@@ -1,64 +1,65 @@
<testcase>
<info>
<keywords>
HTTP
HTTP GET
IDN
followlocation
--write-out
</keywords>
</info>

#
# Server-side
<reply>
<data nocheck="yes">
HTTP/1.1 302 OK swsbounce
Date: Thu, 09 Nov 2010 14:49:00 GMT
Content-Length: 9
Content-Type: text/plain
Location: ./20460001

redirect
</data>
<data1 nocheck="yes">
HTTP/1.1 200 OK
Date: Thu, 09 Nov 2010 14:49:00 GMT
Content-Length: 3
Content-Type: text/plain; charset=us-ascii

OK
</data1>
</reply>

#
# Client-side
<client>
<server>
http
</server>
<features>
idn
</features>
<setenv>
CHARSET=UTF-8
</setenv>
<name>
Connection re-use with IDN host name
</name>

<command>
http://åäö.se:%HTTPPORT/2046 --resolve xn--4cab6c.se:%HTTPPORT:%HOSTIP -w "%{num_connects}\n%{num_redirects}\n%{size_download}\n%{url_effective}\n%{content_type}\n%{response_code}\n" -L
</command>
</client>

#
# Verify data after the test has been "shot"
<verify>
<strip>
^User-Agent:.*
</strip>
<protocol>
<testcase>
<info>
<keywords>
HTTP
HTTP GET
IDN
followlocation
--write-out
</keywords>
</info>

#
# Server-side
<reply>
<data nocheck="yes">
HTTP/1.1 302 OK swsbounce
Date: Thu, 09 Nov 2010 14:49:00 GMT
Content-Length: 9
Content-Type: text/plain
Location: ./20460001

redirect
</data>
<data1 nocheck="yes">
HTTP/1.1 200 OK
Date: Thu, 09 Nov 2010 14:49:00 GMT
Content-Length: 3
Content-Type: text/plain; charset=us-ascii

OK
</data1>
</reply>

#
# Client-side
<client>
<server>
http
</server>
<features>
idn
</features>
<setenv>
CHARSET=UTF-8
LANG=en_US.UTF-8
</setenv>
<name>
Connection re-use with IDN host name
</name>

<command>
http://åäö.se:%HTTPPORT/2046 --resolve xn--4cab6c.se:%HTTPPORT:%HOSTIP -w "%{num_connects}\n%{num_redirects}\n%{size_download}\n%{url_effective}\n%{content_type}\n%{response_code}\n" -L
</command>
</client>

#
# Verify data after the test has been "shot"
<verify>
<strip>
^User-Agent:.*
</strip>
<protocol>
GET /2046 HTTP/1.1
Host: xn--4cab6c.se:%HTTPPORT
Accept: */*
Expand All @@ -67,28 +68,28 @@ GET /20460001 HTTP/1.1
Host: xn--4cab6c.se:%HTTPPORT
Accept: */*

</protocol>

<stdout>
HTTP/1.1 302 OK swsbounce
Date: Thu, 09 Nov 2010 14:49:00 GMT
Content-Length: 9
Content-Type: text/plain
Location: ./20460001

HTTP/1.1 200 OK
Date: Thu, 09 Nov 2010 14:49:00 GMT
Content-Length: 3
Content-Type: text/plain; charset=us-ascii

OK
1
1
3
http://åäö.se:%HTTPPORT/20460001
text/plain; charset=us-ascii
200
</stdout>

</verify>
</testcase>
</protocol>
<stdout>
HTTP/1.1 302 OK swsbounce
Date: Thu, 09 Nov 2010 14:49:00 GMT
Content-Length: 9
Content-Type: text/plain
Location: ./20460001
HTTP/1.1 200 OK
Date: Thu, 09 Nov 2010 14:49:00 GMT
Content-Length: 3
Content-Type: text/plain; charset=us-ascii
OK
1
1
3
http://åäö.se:%HTTPPORT/20460001
text/plain; charset=us-ascii
200
</stdout>
</verify>
</testcase>