php-src/ext/spl/tests/bug28822.phpt
2004-09-29 20:10:12 +00:00

19 lines
347 B
PHP
Executable File

--TEST--
Bug #28822: ArrayObject::offsetExists() works inverted
--SKIPIF--
<?php if (!extension_loaded("spl")) print "skip"; ?>
--FILE--
<?php
$array = new ArrayObject();
$array->offsetSet('key', 'value');
var_dump($array->offsetExists('key'));
var_dump($array->offsetExists('nokey'));
?>
===DONE===
--EXPECT--
bool(true)
bool(false)
===DONE===