public function AbstractProxyFactoryTest::testDisallowsResettingInitializedProxy in Plug 7
File
- lib/
doctrine/ common/ tests/ Doctrine/ Tests/ Common/ Proxy/ AbstractProxyFactoryTest.php, line 103
Class
Namespace
Doctrine\Tests\Common\ProxyCode
public function testDisallowsResettingInitializedProxy() {
$proxyFactory = $this
->getMockForAbstractClass('Doctrine\\Common\\Proxy\\AbstractProxyFactory', array(), '', false);
$proxy = $this
->getMock('Doctrine\\Common\\Proxy\\Proxy');
$proxy
->expects($this
->any())
->method('__isInitialized')
->will($this
->returnValue(true));
$this
->setExpectedException('Doctrine\\Common\\Proxy\\Exception\\InvalidArgumentException');
$proxyFactory
->resetUninitializedProxy($proxy);
}