public function ProxyLogicTest::testFetchingPublicAssociationCausesLazyLoading in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/doctrine/common/tests/Doctrine/Tests/Common/Proxy/ProxyLogicTest.php \Doctrine\Tests\Common\Proxy\ProxyLogicTest::testFetchingPublicAssociationCausesLazyLoading()
File
- vendor/
doctrine/ common/ tests/ Doctrine/ Tests/ Common/ Proxy/ ProxyLogicTest.php, line 159
Class
- ProxyLogicTest
- Test the generated proxies behavior. These tests make assumptions about the structure of LazyLoadableObject
Namespace
Doctrine\Tests\Common\ProxyCode
public function testFetchingPublicAssociationCausesLazyLoading() {
$test = $this;
$this
->configureInitializerMock(1, array(
$this->lazyObject,
'__get',
array(
'publicAssociation',
),
), function () use ($test) {
$test
->setProxyValue('publicAssociation', 'loadedAssociation');
});
$this
->assertSame('loadedAssociation', $this->lazyObject->publicAssociation);
$this
->assertSame('loadedAssociation', $this->lazyObject->publicAssociation);
}