File:
[ELWIX - Embedded LightWeight unIX -] /
embedaddon /
php /
ext /
mbstring /
tests /
mb_ereg1.phpt
Revision
1.1.1.1 (vendor branch):
download - view:
text,
annotated -
select for diffs -
revision graph
Tue Feb 21 23:47:57 2012 UTC (12 years, 6 months ago) by
misho
Branches:
php,
MAIN
CVS tags:
v5_4_3elwix,
v5_4_29p0,
v5_4_29,
v5_4_20p0,
v5_4_20,
v5_4_17p0,
v5_4_17,
v5_3_10,
HEAD
php
--TEST--
mb_ereg() and invalid arguments
--SKIPIF--
<?php if (!function_exists("mb_ereg")) print "skip"; ?>
--FILE--
<?php
$a = array(
array(1,2,3),
array("", "", ""),
array(array(), 1, ""),
array(1, array(), ""),
array(1, "", array()),
);
foreach ($a as $args) {
var_dump(mb_ereg($args[0], $args[1], $args[2]));
var_dump($args);
}
?>
===DONE===
--EXPECTF--
bool(false)
array(3) {
[0]=>
int(1)
[1]=>
int(2)
[2]=>
int(3)
}
Warning: mb_ereg(): empty pattern in %s on line %d
bool(false)
array(3) {
[0]=>
string(0) ""
[1]=>
string(0) ""
[2]=>
string(0) ""
}
Notice: Array to string conversion in %s on line %d
bool(false)
array(3) {
[0]=>
array(0) {
}
[1]=>
int(1)
[2]=>
string(0) ""
}
Warning: mb_ereg() expects parameter 2 to be string, array given in %s on line %d
bool(false)
array(3) {
[0]=>
int(1)
[1]=>
array(0) {
}
[2]=>
string(0) ""
}
bool(false)
array(3) {
[0]=>
int(1)
[1]=>
string(0) ""
[2]=>
array(0) {
}
}
===DONE===
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>