mirror of
https://github.com/curl/curl.git
synced 2026-04-28 09:02:17 +03:00
test1802: test --proxy-headers and --headers setting user-agent
This commit is contained in:
parent
cdd945e486
commit
f9dfabb42a
2 changed files with 64 additions and 1 deletions
|
|
@ -230,7 +230,7 @@ test1680 test1681 test1682 test1683 \
|
|||
test1700 test1701 test1702 test1703 test1704 test1705 test1706 test1707 \
|
||||
test1708 test1709 test1710 test1711 \
|
||||
\
|
||||
test1800 test1801 \
|
||||
test1800 test1801 test1802 \
|
||||
\
|
||||
test1900 test1901 test1902 test1903 test1904 test1905 test1906 test1907 \
|
||||
test1908 test1909 test1910 test1911 test1912 test1913 test1914 test1915 \
|
||||
|
|
|
|||
63
tests/data/test1802
Normal file
63
tests/data/test1802
Normal file
|
|
@ -0,0 +1,63 @@
|
|||
<testcase>
|
||||
<info>
|
||||
<keywords>
|
||||
HTTP
|
||||
HTTP CONNECT
|
||||
</keywords>
|
||||
</info>
|
||||
|
||||
<reply>
|
||||
<data crlf="yes" nocheck="yes">
|
||||
HTTP/1.1 200 OK
|
||||
Date: Tue, 09 Nov 2010 14:49:00 GMT
|
||||
Accept-Ranges: bytes
|
||||
Content-Length: 6
|
||||
Connection: close
|
||||
Content-Type: text/html
|
||||
|
||||
-foo-
|
||||
</data>
|
||||
<connect crlf="yes">
|
||||
HTTP/1.1 200 fine
|
||||
Connection: close
|
||||
Content-Length: 0
|
||||
|
||||
</connect>
|
||||
</reply>
|
||||
|
||||
#
|
||||
# Client-side
|
||||
<client>
|
||||
<features>
|
||||
ftp
|
||||
proxy
|
||||
</features>
|
||||
<server>
|
||||
http
|
||||
</server>
|
||||
<name>
|
||||
HTTP CONNECT with custom headers for proxy and server
|
||||
</name>
|
||||
<command>
|
||||
http://hello/wanted/page -p -x %HOSTIP:%HTTPPORT --header "User-Agent: myapp/1.0" --proxy-header "User-Agent: Benjamin/2" --proxy-header "Host: todeloo" --header "Host: foo"
|
||||
</command>
|
||||
</client>
|
||||
|
||||
#
|
||||
# Verify data after the test has been "shot"
|
||||
<verify>
|
||||
|
||||
<protocol crlf="yes">
|
||||
CONNECT hello:80 HTTP/1.1
|
||||
Proxy-Connection: Keep-Alive
|
||||
User-Agent: Benjamin/2
|
||||
Host: todeloo
|
||||
|
||||
GET /wanted/page HTTP/1.1
|
||||
Host: foo
|
||||
Accept: */*
|
||||
User-Agent: myapp/1.0
|
||||
|
||||
</protocol>
|
||||
</verify>
|
||||
</testcase>
|
||||
Loading…
Add table
Add a link
Reference in a new issue