* renaming tests
[m6w6/ext-http] / tests / HTTPi_Request_002.phpt
1 --TEST--
2 HTTPi_Request GET
3 --SKIPIF--
4 <?php
5 include 'skip.inc';
6 (5 > (int) PHP_VERSION) and die('skip PHP5 is required for HTTPi');
7 ?>
8 --FILE--
9 <?php
10 $r = new HTTPi_Request('http://localhost', HTTP_GET);
11 var_dump($r->send());
12 print_r($r->getResponseInfo());
13 ?>
14 --EXPECTF--
15 Content-type: text/html
16 X-Powered-By: PHP/%s
17
18 bool(true)
19 Array
20 (
21 [effective_url] => http://localhost/
22 [response_code] => 200
23 [http_connectcode] => 0
24 [filetime] => -1
25 [total_time] => %f
26 [namelookup_time] => %f
27 [connect_time] => %f
28 [pretransfer_time] => %f
29 [starttransfer_time] => %f
30 [redirect_time] => %f
31 [redirect_count] => %f
32 [size_upload] => %f
33 [size_download] => %d
34 [speed_download] => %d
35 [speed_upload] => %d
36 [header_size] => %d
37 [request_size] => %d
38 [ssl_verifyresult] => %d
39 [content_length_download] => %d
40 [content_length_upload] => %d
41 [content_type] => text/html%s
42 [httpauth_avail] => %d
43 [proxyauth_avail] => %d
44 )