1
0
mirror of https://github.com/php/php-src.git synced 2026-04-20 14:31:06 +02:00
Files
archived-php-src/ext/imap/tests/imap_headers.phpt
Máté Kocsis 960318ed95 Change argument error message format
Closes GH-5211
2020-02-26 15:00:08 +01:00

28 lines
658 B
PHP

--TEST--
imap_headers() incorrect parameter count
--CREDITS--
Paul Sohier
#phptestfest utrecht
--SKIPIF--
<?php
require_once(__DIR__.'/skipif.inc');
?>
--FILE--
<?php
echo "Checking with no parameters\n";
imap_headers();
echo "Checking with incorrect parameter type\n";
imap_headers('');
imap_headers(false);
?>
--EXPECTF--
Checking with no parameters
Warning: imap_headers() expects exactly 1 parameter, 0 given in %s on line %d
Checking with incorrect parameter type
Warning: imap_headers(): Argument #1 must be of type resource, string given in %s on line %d
Warning: imap_headers(): Argument #1 must be of type resource, bool given in %s on line %d