Annotation of embedaddon/php/Zend/tests/ns_001.phpt, revision 1.1.1.1

1.1       misho       1: --TEST--
                      2: 001: Class in namespace
                      3: --FILE--
                      4: <?php
                      5: namespace test\ns1;
                      6: 
                      7: class Foo {
                      8: 
                      9:   function __construct() {
                     10:     echo __CLASS__,"\n";
                     11:   }
                     12:   
                     13:   function bar() {
                     14:     echo __CLASS__,"\n";
                     15:   }
                     16:   
                     17:   static function baz() {
                     18:     echo __CLASS__,"\n";
                     19:   }
                     20: }
                     21: 
                     22: $x = new Foo;
                     23: $x->bar();
                     24: Foo::baz();
                     25: $y = new \test\ns1\Foo;
                     26: $y->bar();
                     27: \test\ns1\Foo::baz();
                     28: --EXPECT--
                     29: test\ns1\Foo
                     30: test\ns1\Foo
                     31: test\ns1\Foo
                     32: test\ns1\Foo
                     33: test\ns1\Foo
                     34: test\ns1\Foo

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>