diff --git a/tests/data/test15 b/tests/data/test15 index a82fa0cf6..b71588f4e 100644 --- a/tests/data/test15 +++ b/tests/data/test15 @@ -9,7 +9,7 @@ HTTP GET # Server-side -HTTP/1.4 200 OK +HTTP/1.1 200 OK Fake: yes Fake: yes Fake: yes @@ -35,7 +35,7 @@ http://%HOSTIP:%HTTPPORT/want/15 --write-out "%{url_effective} %{http_code} %{si # Verify data after the test has been "shot" -HTTP/1.4 200 OK +HTTP/1.1 200 OK Fake: yes Fake: yes Fake: yes diff --git a/tests/data/test17 b/tests/data/test17 index de03c1de0..fe423b334 100644 --- a/tests/data/test17 +++ b/tests/data/test17 @@ -11,7 +11,7 @@ config file HTTP/1.1 200 OK Funny-head: yesyes -Content-Length: 27 +Content-Length: 27 This is the proof it works diff --git a/tests/data/test24 b/tests/data/test24 index 54147eddf..43e2da5b5 100644 --- a/tests/data/test24 +++ b/tests/data/test24 @@ -41,7 +41,7 @@ Accept: */* 22 -curl: (22) The requested URL returned error: 404 BAD BOY +curl: (22) The requested URL returned error: 404 diff --git a/tests/data/test28 b/tests/data/test28 index 703c6d35b..8aee090c3 100644 --- a/tests/data/test28 +++ b/tests/data/test28 @@ -30,7 +30,11 @@ If this is received, the location following worked HTTP/1.1 301 This is a weirdo text message swsclose Date: Thu, 09 Nov 2010 14:49:00 GMT Server: test-server/fake +%if hyper +Location: /online/1,1795,Welcome,00.html/280002.txt?logout=TRUE +%else Location: /online/1,1795,Welcome,00.html/280002.txt?logout=TRUE +%endif Connection: close HTTP/1.1 200 Followed here fine swsclose diff --git a/tests/data/test31 b/tests/data/test31 index c3b1e04ba..3ec00833e 100644 --- a/tests/data/test31 +++ b/tests/data/test31 @@ -8,6 +8,12 @@ cookiejar # Server-side +# +# The cookies set come in two versions. This is because when curl is built +# with Hyper, the API provides the headers already "sanitized" so we cannot +# compapare with the exact server contents unlesss it too sends the data +# "clean". + HTTP/1.1 200 OK @@ -16,6 +22,7 @@ Server: test-server/fake Content-Length: 4 Content-Type: text/html Funny-head: yesyes +%if !hyper Set-Cookie: foobar=name; domain=anything.com; path=/ ; secure Set-Cookie:ismatch=this ; domain=127.0.0.1; path=/silly/ Set-Cookie: overwrite=this ; domain=127.0.0.1; path=/overwrite/ @@ -57,6 +64,49 @@ Set-Cookie: withspaces= yes within and around ; Set-Cookie: withspaces2 =before equals; Set-Cookie: prespace= yes before; Set-Cookie: securewithspace=after ; secure = +%else +Set-Cookie: foobar=name; domain=anything.com; path=/ ; secure +Set-Cookie: ismatch=this ; domain=127.0.0.1; path=/silly/ +Set-Cookie: overwrite=this ; domain=127.0.0.1; path=/overwrite/ +Set-Cookie: overwrite=this2 ; domain=127.0.0.1; path=/overwrite +Set-Cookie: sec1value=secure1 ; domain=127.0.0.1; path=/secure1/ ; secure +Set-Cookie: sec2value=secure2 ; domain=127.0.0.1; path=/secure2/ ; secure= +Set-Cookie: sec3value=secure3 ; domain=127.0.0.1; path=/secure3/ ; secure= +Set-Cookie: sec4value=secure4 ; secure=; domain=127.0.0.1; path=/secure4/ ; +Set-Cookie: sec5value=secure5 ; secure; domain=127.0.0.1; path=/secure5/ ; +Set-Cookie: sec6value=secure6 ; secure ; domain=127.0.0.1; path=/secure6/ ; +Set-Cookie: sec7value=secure7 ; secure ; domain=127.0.0.1; path=/secure7/ ; +Set-Cookie: sec8value=secure8 ; secure= ; domain=127.0.0.1; path=/secure8/ ; +Set-Cookie: secure=very1 ; secure=; domain=127.0.0.1; path=/secure9/; +Set-Cookie: httpo1=value1 ; domain=127.0.0.1; path=/p1/; httponly +Set-Cookie: httpo2=value2 ; domain=127.0.0.1; path=/p2/; httponly= +Set-Cookie: httpo3=value3 ; httponly; domain=127.0.0.1; path=/p3/; +Set-Cookie: httpo4=value4 ; httponly=; domain=127.0.0.1; path=/p4/; +Set-Cookie: httponly=myvalue1 ; domain=127.0.0.1; path=/p4/; httponly +Set-Cookie: httpandsec=myvalue2 ; domain=127.0.0.1; path=/p4/; httponly; secure +Set-Cookie: httpandsec2=myvalue3; domain=127.0.0.1; path=/p4/; httponly=; secure +Set-Cookie: httpandsec3=myvalue4 ; domain=127.0.0.1; path=/p4/; httponly; secure= +Set-Cookie: httpandsec4=myvalue5 ; domain=127.0.0.1; path=/p4/; httponly=; secure= +Set-Cookie: httpandsec5=myvalue6 ; domain=127.0.0.1; path=/p4/; secure; httponly= +Set-Cookie: httpandsec6=myvalue7 ; domain=127.0.0.1; path=/p4/; secure=; httponly= +Set-Cookie: httpandsec7=myvalue8 ; domain=127.0.0.1; path=/p4/; secure; httponly +Set-Cookie: httpandsec8=myvalue9; domain=127.0.0.1; path=/p4/; secure=; httponly +Set-Cookie: partmatch=present; domain=127.0.0.1 ; path=/; +Set-Cookie: eat=this; domain=moo.foo.moo; +Set-Cookie: eat=this-too; domain=.foo.moo; +Set-Cookie: nodomainnovalue +Set-Cookie: nodomain=value; expires=Fri Feb 13 11:56:27 GMT 2037 +Set-Cookie: novalue; domain=reallysilly +Set-Cookie: test=yes; domain=foo.com; expires=Sat Feb 2 11:56:27 GMT 2030 +Set-Cookie: test2=yes; domain=se; expires=Sat Feb 2 11:56:27 GMT 2030 +Set-Cookie: magic=yessir; path=/silly/; HttpOnly +Set-Cookie: blexp=yesyes; domain=127.0.0.1; domain=127.0.0.1; expiry=totally bad; +Set-Cookie: partialip=nono; domain=.0.0.1; +Set-Cookie: withspaces= yes within and around ; +Set-Cookie: withspaces2 =before equals; +Set-Cookie: prespace= yes before; +Set-Cookie: securewithspace=after ; secure = +%endif boo diff --git a/tests/data/test40 b/tests/data/test40 index 42bd8e13b..566e1e512 100644 --- a/tests/data/test40 +++ b/tests/data/test40 @@ -26,7 +26,11 @@ body HTTP/1.1 302 OK swsclose +%if !hyper Location: ../moo.html/?name=d a niel&testcase=/400002 +%else +Location: ../moo.html/?name=d a niel&testcase=/400002 +%endif Date: Thu, 09 Nov 2010 14:49:00 GMT Connection: close diff --git a/tests/data/test42 b/tests/data/test42 index abb3412ee..cfb2eb380 100644 --- a/tests/data/test42 +++ b/tests/data/test42 @@ -26,7 +26,11 @@ body HTTP/1.1 302 OK swsclose +%if !hyper Location: ../m o o.html/420002 +%else +Location: ../m o o.html/420002 +%endif Date: Thu, 09 Nov 2010 14:49:00 GMT Connection: close diff --git a/tests/data/test54 b/tests/data/test54 index 24f081954..3878d53dc 100644 --- a/tests/data/test54 +++ b/tests/data/test54 @@ -11,7 +11,7 @@ followlocation HTTP/1.1 302 This is a weirdo text message swsclose Connection: close -Location: +Location: This server reply is for testing diff --git a/tests/data/test56 b/tests/data/test56 index 394ac3574..ee21c9d21 100644 --- a/tests/data/test56 +++ b/tests/data/test56 @@ -52,7 +52,11 @@ Accept: */* Transfer-Encoding: chunked Content-Type: application/x-www-form-urlencoded +%if hyper +C +%else c +%endif we post this 0 diff --git a/tests/data/test60 b/tests/data/test60 index 09cd54f83..885ca731d 100644 --- a/tests/data/test60 +++ b/tests/data/test60 @@ -43,7 +43,9 @@ Host: %HOSTIP:%HTTPPORT User-Agent: curl/%VERSION Accept: */* Transfer-Encoding: chunked +%if !hyper Content-Length: 1 +%endif Expect: 100-continue 13