Opis\Colibri\Test\ClosureTest::testClosureBindToObjectStaticScope PHP Метод

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

    public function testClosureBindToObjectStaticScope()
    {
        $a = new A();
        $b = function () {
            return static::aStaticProtected();
        };
        $b = $b->bindTo(null, __NAMESPACE__ . "\\A");
        $u = $this->s($b);
        $this->assertEquals('static protected called', $u());
    }