• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<testcase>
2<info>
3<keywords>
4HTTP
5HTTP GET
6CURLOPT_CONNECT_TO
7</keywords>
8</info>
9
10#
11# Server-side
12<reply>
13<data nocheck="yes">
14HTTP/1.1 200 OK
15Date: Thu, 09 Nov 2010 14:49:00 GMT
16Content-Length: 3
17Content-Type: text/plain
18
19OK
20</data>
21</reply>
22
23#
24# Client-side
25<client>
26<server>
27http
28</server>
29 <name>
30Connect to specific host: Do not mix connections with and without a "connect to host"
31 </name>
32
33 <command>
34http://www.example.com:%HTTPPORT/2052 --resolve www.example.com:%HTTPPORT:%HOSTIP -w "%{num_connects}\n" --next --resolve -www.example.com:%HTTPPORT --connect-to ::%HOSTIP:%HTTPPORT http://www.example.com:%HTTPPORT/2052 -w "%{num_connects}\n"
35</command>
36</client>
37
38#
39# Verify data after the test has been "shot"
40<verify>
41<protocol>
42GET /2052 HTTP/1.1
43Host: www.example.com:%HTTPPORT
44User-Agent: curl/%VERSION
45Accept: */*
46
47GET /2052 HTTP/1.1
48Host: www.example.com:%HTTPPORT
49User-Agent: curl/%VERSION
50Accept: */*
51
52</protocol>
53
54<stdout>
55HTTP/1.1 200 OK
56Date: Thu, 09 Nov 2010 14:49:00 GMT
57Content-Length: 3
58Content-Type: text/plain
59
60OK
611
62OK
631
64</stdout>
65
66</verify>
67</testcase>
68