From fe67ba6d2b2a0ed9d86d99003d51691fce0ee69a Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Thu, 14 Jun 2001 12:05:30 +0000 Subject: three more HTTP tests added from the old test suite --- tests/data/Makefile.am | 8 ++++---- tests/data/test15 | 44 ++++++++++++++++++++++++++++++++++++++++++++ tests/data/test16 | 37 +++++++++++++++++++++++++++++++++++++ tests/data/test17 | 42 ++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 127 insertions(+), 4 deletions(-) create mode 100644 tests/data/test15 create mode 100644 tests/data/test16 create mode 100644 tests/data/test17 (limited to 'tests') diff --git a/tests/data/Makefile.am b/tests/data/Makefile.am index 3a00b2d25..2d25741c9 100644 --- a/tests/data/Makefile.am +++ b/tests/data/Makefile.am @@ -5,7 +5,7 @@ test: [ -f test1 ] || ln -s $(srcdir)/test* . EXTRA_DIST = \ -test1 test102 test106 test13 test3 test400 test8 \ -test10 test103 test107 test14 test300 test5 test9 \ -test100 test104 test11 test2 test33 test6 \ -test101 test105 test12 test200 test4 test7 +test1 test102 test106 test13 test17 test300 test5 test9 \ +test10 test103 test107 test14 test2 test33 test6 \ +test100 test104 test11 test15 test200 test4 test7 \ +test101 test105 test12 test16 test3 test400 test8 diff --git a/tests/data/test15 b/tests/data/test15 new file mode 100644 index 000000000..4a8953739 --- /dev/null +++ b/tests/data/test15 @@ -0,0 +1,44 @@ +# Server-side + + +HTTP/1.4 200 OK +Fake: yes +Fake: yes +Fake: yes + +Repeated nonsense-headers + + + +# Client-side + + +--write-out test + + +http://%HOSTIP:%HOSTPORT/want/15 --write-out '%{url_effective} %{http_code} %{size_download}\n' + + + +# Verify data after the test has been "shot" + + +HTTP/1.4 200 OK +Fake: yes +Fake: yes +Fake: yes + +Repeated nonsense-headers +http://127.0.0.1:8999/want/15 200 26 + + +^User-Agent:.* + + +GET /want/15 HTTP/1.1 +Host: 127.0.0.1:8999 +Pragma: no-cache +Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, */* + + + diff --git a/tests/data/test16 b/tests/data/test16 new file mode 100644 index 000000000..eadcedd83 --- /dev/null +++ b/tests/data/test16 @@ -0,0 +1,37 @@ +# Server-side + + +HTTP/1.1 200 OK +Date: Thu, 09 Nov 2010 14:49:00 GMT +Server: test-server/fake +Content-Type: text/html +Funny-head: yesyes + +the content goes here + + + +# Client-side + + +HTTP with proxy athorization + + + -U fake@user:§§§looooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooong -x %HOSTIP:%HOSTPORT http://we.want.that.site.com/16 + + + +# Verify data after the test has been "shot" + + +^User-Agent:.* + + +GET http://we.want.that.site.com/16 HTTP/1.1 +Proxy-authorization: Basic ZmFrZUB1c2VyOqenp2xvb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb28= +Host: we.want.that.site.com +Pragma: no-cache +Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, */* + + + diff --git a/tests/data/test17 b/tests/data/test17 new file mode 100644 index 000000000..ae799bd62 --- /dev/null +++ b/tests/data/test17 @@ -0,0 +1,42 @@ +# Server-side + + +HTTP/1.1 200 OK +Funny-head: yesyes + +This is the proof it works + + + +# Client-side + + +HTTP with config file on stdin + + +# +# Use a silly request without '--': +request MOOO +# +# Set the user-agent using a short-option: +-A "agent007 license to drill\t" +# +# long option *with* '--': +--max-time 180 + + +-K - %HOSTIP:%HOSTPORT/that.site.com/17 + + + +# Verify data after the test has been "shot" + + +MOOO /that.site.com/17 HTTP/1.1 +User-Agent: agent007 license to drill +Host: 127.0.0.1:8999 +Pragma: no-cache +Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, */* + + + -- cgit v1.2.3