예제 #1
0
파일: ScopedTest.php 프로젝트: mvc5/tests
 /**
  *
  */
 function test_scoped_with_object()
 {
     $config = new Config();
     $resolver = new Resolver();
     $resolver->scope($config);
     $callback = function () {
         return $this;
     };
     $scoped = $resolver->scoped($callback);
     $this->assertInstanceOf(\Closure::class, $scoped);
     $this->assertTrue($config === $scoped());
 }