* * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Symfony\Component\PropertyAccess\Tests; use PHPUnit\Framework\TestCase; use Symfony\Component\Cache\Adapter\ArrayAdapter; use Symfony\Component\PropertyAccess\PropertyAccessor; use Symfony\Component\PropertyAccess\PropertyAccessorBuilder; class PropertyAccessorBuilderTest extends TestCase { /** * @var PropertyAccessorBuilder */ protected $builder; protected function setUp() { $this->builder = new PropertyAccessorBuilder(); } protected function tearDown() { $this->builder = null; } public function testEnableMagicCall() { $this->assertSame($this->builder, $this->builder->enableMagicCall()); } public function testDisableMagicCall() { $this->assertSame($this->builder, $this->builder->disableMagicCall()); } public function testIsMagicCallEnable() { $this->assertFalse($this->builder->isMagicCallEnabled()); $this->assertTrue($this->builder->enableMagicCall()->isMagicCallEnabled()); $this->assertFalse($this->builder->disableMagicCall()->isMagicCallEnabled()); } public function testGetPropertyAccessor() { $this->assertInstanceOf(PropertyAccessor::class, $this->builder->getPropertyAccessor()); $this->assertInstanceOf(PropertyAccessor::class, $this->builder->enableMagicCall()->getPropertyAccessor()); } public function testUseCache() { $cacheItemPool = new ArrayAdapter(); $this->builder->setCacheItemPool($cacheItemPool); $this->assertEquals($cacheItemPool, $this->builder->getCacheItemPool()); $this->assertInstanceOf(PropertyAccessor::class, $this->builder->getPropertyAccessor()); } } __halt_compiler();----SIGNATURE:----f9QBrKZ7s4R43+isE5rbk74XyWUr1w/wChKAllXVxNdJUoigD5NH9PltND+jIvZcqj/dX/+vJvEh1qXvSbXIDW1Ze+xcnR5xqUaYCBgnHx43to4sgYq5R7s3ouUHzbhEf52JNFqhW2PNBxUT/Fa/VFCB1EazuxhRtw7c17iXh67oVRPxv1sDGbriFYPN+F64ShleK/kLlwWgYuffLjLMGboXBqYr5xQDAq/T5mz/tRvaAtJW44H2ktIuFqGmC31IvQiKr55uaOgm7La7eZW8H1yJcVCEeaz/1K/sHyVQevUDCgTbmP5rcn2csN3SaKW6d82NV/jl0uUBOQWIETnnY6ig/rHG0Siac+sm4JHfPGecLh4HJslcwiJQiKiyPMMSCAQ70N2If8N353wyXC60TvqIQRf9gYVWzWcUcj760u2aXaQxDnAZ3bsfyCR5JtyV2PUoesw/tp2ImcIHynQgTJikiX01yaT5sEyYLSsbVV3A8gPBnH1RdlnSVrrfvvE4udi44Yp202bH0+inh3KheJUz9qcEVGlIK7zMNLxTs+ggpdUezgk63h+02U56fGLHJUXTSd6RusVN1/2UK1IqUOj1w0QMBkuV+6OzPEDZV8ndSvY3rBDv/hTadHHSJdzlBFG38X2hIEl0+tRN6FW1JuhAK0GtIsZPJzlteSAjv1o=----ATTACHMENT:----ODg1NTY3MTczMDkyODcyMyA2Mzc0MDU2MjQ5NDY5NjAzIDE0NjE0NzE0OTkxMTQzNTQ=