xref: /PHP-5.6/Zend/tests/bug60833.phpt (revision 184db665)
1--TEST--
2Bug #60833 (self, parent, static behave inconsistently case-sensitive)
3--FILE--
4<?php
5class A {
6	static $x = "A";
7	function testit() {
8		$this->v1 = new sELF;
9		$this->v2 = new SELF;
10	}
11}
12
13class B extends A {
14	static $x = "B";
15	function testit() {
16		PARENT::testit();
17		$this->v3 = new sELF;
18		$this->v4 = new PARENT;
19		$this->v4 = STATIC::$x;
20	}
21}
22$t = new B();
23$t->testit();
24var_dump($t);
25?>
26--EXPECTF--
27object(B)#%d (4) {
28  ["v1"]=>
29  object(A)#%d (0) {
30  }
31  ["v2"]=>
32  object(A)#%d (0) {
33  }
34  ["v3"]=>
35  object(B)#%d (0) {
36  }
37  ["v4"]=>
38  string(1) "B"
39}
40
41