From 5591550167092c0e5f307b3c2c87f44518e7159f Mon Sep 17 00:00:00 2001 From: Dan Fandrich Date: Wed, 21 Jan 2009 04:42:47 +0000 Subject: Fixed a couple more locale-dependent toupper conversions, mainly for clarity. This does fix one problem that causes ;type=i FTP URLs to fail in the Turkish locale when CURLOPT_PROXY_TRANSFER_MODE is used (test case 561) Added tests 561 and 1092 through 1094 to test various combinations of ;type= and ;mode= URLs that could potentially fail in the Turkish locale. --- tests/data/Makefile.am | 2 +- tests/data/test1091 | 46 +++++++++++++++++++++++++++++++++++ tests/data/test1092 | 55 +++++++++++++++++++++++++++++++++++++++++ tests/data/test1093 | 44 +++++++++++++++++++++++++++++++++ tests/data/test1094 | 50 ++++++++++++++++++++++++++++++++++++++ tests/data/test561 | 66 ++++++++++++++++++++++++++++++++++++++++++++++++++ 6 files changed, 262 insertions(+), 1 deletion(-) create mode 100644 tests/data/test1091 create mode 100644 tests/data/test1092 create mode 100644 tests/data/test1093 create mode 100644 tests/data/test1094 create mode 100644 tests/data/test561 (limited to 'tests') diff --git a/tests/data/Makefile.am b/tests/data/Makefile.am index 85a90dc95..4a459e012 100644 --- a/tests/data/Makefile.am +++ b/tests/data/Makefile.am @@ -60,7 +60,7 @@ EXTRA_DIST = test1 test108 test117 test127 test20 test27 test34 test46 \ test1072 test1073 test1074 test1075 test1076 test1077 test1078 test1079 \ test1080 test1081 test1082 test1083 test1084 test1085 test633 test634 \ test635 test636 test637 test558 test559 test1086 test1087 test1088 \ - test1089 test1090 + test1089 test1090 test1091 test1092 test1093 test1094 filecheck: @mkdir test-place; \ diff --git a/tests/data/test1091 b/tests/data/test1091 new file mode 100644 index 000000000..f3ce8608a --- /dev/null +++ b/tests/data/test1091 @@ -0,0 +1,46 @@ + +# based on test 143 + + +FTP +RETR +type= + + + +# Server-side + + +bla bla bla + + + +# Client-side + + +ftp + + +FTP URL with type=i + + +"ftp://%HOSTIP:%FTPPORT/%2ftmp/moo/1091;type=i" --use-ascii + + + +# Verify data after the test has been "shot" + + +USER anonymous +PASS ftp@example.com +PWD +CWD /tmp +CWD moo +EPSV +TYPE I +SIZE 1091 +RETR 1091 +QUIT + + + diff --git a/tests/data/test1092 b/tests/data/test1092 new file mode 100644 index 000000000..26c4e059f --- /dev/null +++ b/tests/data/test1092 @@ -0,0 +1,55 @@ + + + +FTP +HTTP +HTTP GET +HTTP proxy + + +# +# Server-side + + +HTTP/1.0 200 OK +Date: Thu, 09 Nov 2010 14:49:00 GMT +Server: test-server/fake swsclose +Content-Type: text/html +Funny-head: yesyes + +contents + + + +# +# Client-side + + +http + + +ftp + + +FTP over HTTP proxy + + +"ftp://%HOSTIP:%HTTPPORT/we/want/that/page/1092;type=i" --use-ascii -x %HOSTIP:%HTTPPORT + + + +# +# Verify data after the test has been "shot" + + +^User-Agent:.* + + +GET ftp://%HOSTIP:%HTTPPORT/we/want/that/page/1092;type=i HTTP/1.1 +Host: %HOSTIP:%HTTPPORT +Accept: */* +Proxy-Connection: Keep-Alive + + + + diff --git a/tests/data/test1093 b/tests/data/test1093 new file mode 100644 index 000000000..dbcfd9f7a --- /dev/null +++ b/tests/data/test1093 @@ -0,0 +1,44 @@ + + + +TFTP +TFTP RRQ +mode= + + + +# +# Server-side + + +a chunk of +data +returned + to client + + + +# +# Client-side + + +tftp + + +TFTP retrieve with mode=i + + +"tftp://%HOSTIP:%TFTPPORT//1093;mode=i" --use-ascii --trace-ascii log/traceit + + + +# +# Verify pseudo protocol after the test has been "shot" + + +opcode: 1 +filename: /1093 +mode: octet + + + diff --git a/tests/data/test1094 b/tests/data/test1094 new file mode 100644 index 000000000..29965505f --- /dev/null +++ b/tests/data/test1094 @@ -0,0 +1,50 @@ + + + +TFTP +TFTP RRQ +mode= + + + +# +# Server-side + + +a chunk of +data +returned + to client + + +a chunk of +data +returned + to client + + + +# +# Client-side + + +tftp + + +TFTP retrieve with mode=netascii + + +"tftp://%HOSTIP:%TFTPPORT//1094;mode=netascii" --trace-ascii log/traceit + + + +# +# Verify pseudo protocol after the test has been "shot" + + +opcode: 1 +filename: /1094 +mode: netascii + + + diff --git a/tests/data/test561 b/tests/data/test561 new file mode 100644 index 000000000..18e827c10 --- /dev/null +++ b/tests/data/test561 @@ -0,0 +1,66 @@ + + + +FTP +HTTP proxy +CURLOPT_PROXY_TRANSFER_MODE +CURLOPT_PROXY +type= + + + +# +# Server-side + + +HTTP/1.1 200 OK swsclose +Date: Thu, 09 Nov 2010 14:49:00 GMT +Server: test-server/fake +Last-Modified: Tue, 13 Jun 2000 12:10:00 GMT +ETag: "21025-dc7-39462498" +Accept-Ranges: bytes +Content-Length: 6 + +hello + + + +# +# Client-side + + +http + + +ftp + + +lib549 + + +FTP RETR with CURLOPT_PROXY_TRANSFER_MODE, ASCII transfer and type=i + +# first URL then proxy + +"ftp://www.haxx.se/moo/561;type=i" http://%HOSTIP:%HTTPPORT ascii + + + +# +# Verify data after the test has been "shot" + + +^User-Agent:.* + + +GET ftp://www.haxx.se/moo/561;type=i HTTP/1.1 +Host: www.haxx.se:21 +Accept: */* +Proxy-Connection: Keep-Alive + + + +hello + + + -- cgit v1.2.3