Tests for { @author Marco Pivetta <ocramius@gmail.com>
@covers \Symfony\Component\DependencyInjection\LazyProxy\Instantiator\RealServiceInstantiator
Expanded class hierarchy of RealServiceInstantiatorTest
\Symfony\Component\DependencyInjection\Instantiator\RealServiceInstantiator}
class RealServiceInstantiatorTest extends \PHPUnit_Framework_TestCase {
public function testInstantiateProxy() {
$instantiator = new RealServiceInstantiator();
$instance = new \stdClass();
$container = $this
->getMock('Symfony\\Component\\DependencyInjection\\ContainerInterface');
$callback = function () use ($instance) {
return $instance;
};
$this
->assertSame($instance, $instantiator
->instantiateProxy($container, new Definition(), 'foo', $callback));
}
}