xref: /PHP-7.0/ext/curl/tests/curl_basic_009.phpt (revision 84b17658)
1--TEST--
2Test curl_error() & curl_errno() function with problematic protocol
3--CREDITS--
4TestFest 2009 - AFUP - Perrick Penet <perrick@noparking.net>
5--SKIPIF--
6<?php if (!extension_loaded("curl")) print "skip"; ?>
7--FILE--
8<?php
9
10$url = uniqid()."://www.".uniqid().".".uniqid();
11$ch = curl_init();
12curl_setopt($ch, CURLOPT_URL, $url);
13
14curl_exec($ch);
15var_dump(curl_error($ch));
16var_dump(curl_errno($ch));
17curl_close($ch);
18
19
20?>
21--EXPECTF--
22%unicode|string%(%d) "%Srotocol%s"
23int(1)
24