cvs: php-src(PHP_5_0) /ext/standard/tests/array bug30833.phpt
| From: | Antony Dovgal | Date: | Wed, 13 Apr 2005 08:24:00 +0000 |
| Subject: | cvs: php-src(PHP_5_0) /ext/standard/tests/array bug30833.phpt | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-31370@lists.php.net to get a copy of this message | ||
tony2001 Wed Apr 13 04:24:00 2005 EDT
Added files: (Branch: PHP_5_0)
/php-src/ext/standard/tests/array bug30833.phpt
Log:
MFH: add testcase for bug #30833
http://cvs.php.net/co.php/php-src/ext/standard/tests/array/bug30833.phpt?r=1.1&p=1
Index: php-src/ext/standard/tests/array/bug30833.phpt
+++ php-src/ext/standard/tests/array/bug30833.phpt
--TEST--
bug #30833 (array_count_values() modifying input array)
--FILE--
<?php
$foo = array('abc', '0000');
var_dump($foo);
$count = array_count_values( $foo );
var_dump($count);
var_dump($foo);
echo "Done\n";
?>
--EXPECT--
array(2) {
[0]=>
string(3) "abc"
[1]=>
string(4) "0000"
}
array(2) {
["abc"]=>
int(1)
[0]=>
int(1)
}
array(2) {
[0]=>
string(3) "abc"
[1]=>
string(4) "0000"
}
Done