diff options
author | Marcus Boerger <helly@php.net> | 2004-09-19 11:53:30 +0000 |
---|---|---|
committer | Marcus Boerger <helly@php.net> | 2004-09-19 11:53:30 +0000 |
commit | dfe23e34d9647e82e292d8fe9fca93c11ed13d07 (patch) | |
tree | 20f3a30eb9793ea5c426a35c9d567e9609d09f19 | |
parent | 980424a8346029a245a5682b3619789ee41bdfe3 (diff) | |
download | php-git-dfe23e34d9647e82e292d8fe9fca93c11ed13d07.tar.gz |
Add new test
-rwxr-xr-x | ext/reflection/tests/bug30146.phpt | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/ext/reflection/tests/bug30146.phpt b/ext/reflection/tests/bug30146.phpt new file mode 100755 index 0000000000..4f48985dcc --- /dev/null +++ b/ext/reflection/tests/bug30146.phpt @@ -0,0 +1,23 @@ +--TEST-- +Bug #30146 (ReflectionProperty->getValue() requires instance for static property) +--FILE-- +<?php +class test { + static public $a = 1; +} + +$r = new ReflectionProperty('test', 'a'); +var_dump($r->getValue(null)); + +$r->setValue(NULL, 2); +var_dump($r->getValue()); + +$r->setValue(3); +var_dump($r->getValue()); +?> +===DONE=== +--EXPECT-- +int(1) +int(2) +int(3) +===DONE===
\ No newline at end of file |