1--TEST--
2Test curl_copy_handle() function with basic functionality
3--CREDITS--
4Francesco Fullone ff@ideato.it
5#PHPTestFest Cesena Italia on 2009-06-20
6--SKIPIF--
7<?php
8	if (!extension_loaded("curl")) exit("skip curl extension not loaded");
9?>
10--FILE--
11<?php
12echo "*** Testing curl_copy_handle(): basic ***\n";
13
14// create a new cURL resource
15$ch = curl_init();
16
17// set URL and other appropriate options
18curl_setopt($ch, CURLOPT_URL, 'http://www.example.com/');
19curl_setopt($ch, CURLOPT_HEADER, 0);
20
21// copy the handle
22$ch2 = curl_copy_handle($ch);
23
24var_dump(curl_getinfo($ch) === curl_getinfo($ch2));
25?>
26===DONE===
27--EXPECTF--
28*** Testing curl_copy_handle(): basic ***
29bool(true)
30===DONE===
31