Skip to content

Commit 1775943

Browse files
pauloelrrogeriopradoj
authored andcommitted
Test PHP Init Fail Without Params
1 parent 7f12392 commit 1775943

File tree

1 file changed

+27
-0
lines changed

1 file changed

+27
-0
lines changed
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
--TEST--
2+
Test curl_multi_init() fail if any parameter is passed
3+
--CREDITS--
4+
Paulo Eduardo <pauloelr [at] gmail [dot] com>
5+
#testfest SP 2014
6+
--SKIPIF--
7+
<?php if (!extension_loaded("curl")) print "skip"; ?>
8+
--FILE--
9+
<?php
10+
/* Prototype : resource curl_multi_init(void)
11+
* Description : Returns a new cURL multi handle
12+
* Source code : ext/curl/multi.c
13+
* Test documentation: http://wiki.php.net/qa/temp/ext/curl
14+
*/
15+
16+
// start testing
17+
18+
//create the multiple cURL handle
19+
$mh = curl_multi_init('test');
20+
var_dump($mh);
21+
22+
?>
23+
===DONE===
24+
--EXPECTF--
25+
Warning: curl_multi_init() expects exactly 0 parameters, %d given in %s on line %d
26+
NULL
27+
===DONE===

0 commit comments

Comments
 (0)