From 96cf615e9dec951b2c4244780b5f3fe2fb303f5b Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Wed, 27 Oct 2004 21:29:55 +0000 Subject: Added --retry and --retry-delay first attempt with four related test cases. --- tests/data/Makefile.am | 2 +- tests/data/test195 | 30 ++++++++++++++++++++++ tests/data/test196 | 32 +++++++++++++++++++++++ tests/data/test197 | 69 ++++++++++++++++++++++++++++++++++++++++++++++++++ tests/data/test198 | 64 ++++++++++++++++++++++++++++++++++++++++++++++ 5 files changed, 196 insertions(+), 1 deletion(-) create mode 100644 tests/data/test195 create mode 100644 tests/data/test196 create mode 100644 tests/data/test197 create mode 100644 tests/data/test198 (limited to 'tests') diff --git a/tests/data/Makefile.am b/tests/data/Makefile.am index 7298caf7a..cd1d82bd3 100644 --- a/tests/data/Makefile.am +++ b/tests/data/Makefile.am @@ -27,7 +27,7 @@ EXTRA_DIST = test1 test108 test117 test127 test20 test27 test34 test46 \ test172 test204 test205 test173 test174 test175 test176 test177 \ test513 test514 test178 test179 test180 test181 test182 test183 \ test184 test185 test186 test187 test188 test189 test191 test192 \ - test193 test194 + test193 test194 test195 test196 test197 test198 # The following tests have been removed from the dist since they no longer # work. We need to fix the test suite's FTPS server first, then bring them diff --git a/tests/data/test195 b/tests/data/test195 new file mode 100644 index 000000000..c736e53b3 --- /dev/null +++ b/tests/data/test195 @@ -0,0 +1,30 @@ +# Server-side + + + +# Client-side + + +ftp + + +FTP response 530 after PASS, temporarily not allowed access + + +ftp://%HOSTIP:%FTPPORT/195 + + +REPLY PASS 530 temporarily not available + + + +# Verify data after the test has been "shot" + + +10 + + +USER anonymous +PASS curl_by_daniel@haxx.se + + diff --git a/tests/data/test196 b/tests/data/test196 new file mode 100644 index 000000000..06eeeb5f9 --- /dev/null +++ b/tests/data/test196 @@ -0,0 +1,32 @@ +# Server-side + + + +# Client-side + + +ftp + + +FTP transient error, retry request once + + +ftp://%HOSTIP:%FTPPORT/196 --retry 1 + + +REPLY PASS 530 temporarily not available + + + +# Verify data after the test has been "shot" + + +10 + + +USER anonymous +PASS curl_by_daniel@haxx.se +USER anonymous +PASS curl_by_daniel@haxx.se + + diff --git a/tests/data/test197 b/tests/data/test197 new file mode 100644 index 000000000..2f73e8e92 --- /dev/null +++ b/tests/data/test197 @@ -0,0 +1,69 @@ +# +# Server-side + + +HTTP/1.1 503 OK swsbounce +Date: Thu, 09 Nov 2010 14:49:00 GMT +Content-Length: 21 + +server not available + + +HTTP/1.1 200 OK +Date: Thu, 09 Nov 2010 14:49:00 GMT +Content-Length: 3 +Connection: close + +ok + + + + +# +# Client-side + + +http + + +HTTP GET --retry on 503 error with output to stdout + + +http://%HOSTIP:%HTTPPORT/197 --retry 1000 + + + +# +# Verify data after the test has been "shot" + + +^User-Agent:.* + + +GET /197 HTTP/1.1 +Host: 127.0.0.1:%HTTPPORT +Pragma: no-cache +Accept: */* + +GET /197 HTTP/1.1 +Host: 127.0.0.1:%HTTPPORT +Pragma: no-cache +Accept: */* + + + + +HTTP/1.1 503 OK swsbounce +Date: Thu, 09 Nov 2010 14:49:00 GMT +Content-Length: 21 + +server not available +HTTP/1.1 200 OK +Date: Thu, 09 Nov 2010 14:49:00 GMT +Content-Length: 3 +Connection: close + +ok + + + diff --git a/tests/data/test198 b/tests/data/test198 new file mode 100644 index 000000000..90d52ded3 --- /dev/null +++ b/tests/data/test198 @@ -0,0 +1,64 @@ +# +# Server-side + + +HTTP/1.1 503 OK swsbounce +Date: Thu, 09 Nov 2010 14:49:00 GMT +Content-Length: 21 + +server not available + + +HTTP/1.1 200 OK +Date: Thu, 09 Nov 2010 14:49:00 GMT +Content-Length: 3 +Connection: close + +ok + + + +HTTP/1.1 200 OK +Date: Thu, 09 Nov 2010 14:49:00 GMT +Content-Length: 3 +Connection: close + +ok + + + + +# +# Client-side + + +http + + +HTTP GET --retry on 503 error with output to file + + +http://%HOSTIP:%HTTPPORT/198 --retry 1000 + + + +# +# Verify data after the test has been "shot" + + +^User-Agent:.* + + +GET /198 HTTP/1.1 +Host: 127.0.0.1:%HTTPPORT +Pragma: no-cache +Accept: */* + +GET /198 HTTP/1.1 +Host: 127.0.0.1:%HTTPPORT +Pragma: no-cache +Accept: */* + + + + -- cgit v1.2.3