xref: /curl/tests/data/test1543 (revision 5121d98c)
1<testcase>
2<info>
3<keywords>
4HTTP
5CURLOPT_CURLU
6</keywords>
7</info>
8#
9# Similar to 1518 but using CURLOPT_CURLU
10#
11# Server-side
12<reply>
13<data2 nocheck="yes">
14HTTP/1.1 200 OK
15Date: Thu, 17 Mar 2016 14:41:00 GMT
16Server: test-server/fake
17X-Special: swsclose
18Content-Length: 0
19Connection: close
20
21</data2>
22<data nocheck="yes">
23HTTP/1.1 302 redirect
24Date: Thu, 17 Mar 2016 14:41:00 GMT
25Server: test-server/fake
26Content-Type: text/plain; charset=US-ASCII
27Location: ../%TESTNUMBER0002
28Content-Length: 0
29Connection: close
30
31</data>
32</reply>
33
34# Client-side
35<client>
36<server>
37http
38</server>
39# tool is what to use instead of 'curl'
40<tool>
41lib%TESTNUMBER
42</tool>
43
44<name>
45CURLOPT_CURLU, URL with space and CURLINFO_EFFECTIVE_URL
46</name>
47<command>
48"http://%HOSTIP:%HTTPPORT/ /with/ space/ /file"
49</command>
50</client>
51
52#
53# Verify data after the test has been "shot"
54<verify>
55<protocol>
56GET /%20/with/%20space/%20/file HTTP/1.1
57Host: %HOSTIP:%HTTPPORT
58Accept: */*
59
60GET /%20/with/%20space/%TESTNUMBER0002 HTTP/1.1
61Host: %HOSTIP:%HTTPPORT
62Accept: */*
63
64</protocol>
65<stdout>
66res 0
67status 200
68redirects 1
69effectiveurl http://%HOSTIP:%HTTPPORT/%20/with/%20space/%TESTNUMBER0002
70redirecturl blank
71</stdout>
72<errorcode>
730
74</errorcode>
75</verify>
76</testcase>
77