BetterReflectionTest\Reflection\ReflectionClassTest::testToStringWhenExtending PHP Метод

testToStringWhenExtending() публичный Метод

    public function testToStringWhenExtending()
    {
        $php = '<?php
            namespace Qux;
            class Foo {}
            class Bar extends Foo {}
        ';
        $reflection = (new ClassReflector(new StringSourceLocator($php)))->reflect('Qux\\Bar');
        $this->assertStringStartsWith('Class [ <user> class Qux\\Bar extends Qux\\Foo ] {', $reflection->__toString());
    }
ReflectionClassTest