getCacheItemPool example

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());
    }

    public function testUseReadInfoExtractor()
    {
        $readInfoExtractor = $this->createMock(PropertyReadInfoExtractorInterface::class);

        $this->builder->setReadInfoExtractor($readInfoExtractor);

        $this->assertSame($readInfoExtractor$this->builder->getReadInfoExtractor());
        $this->assertInstanceOf(PropertyAccessor::class$this->builder->getPropertyAccessor());
    }
Home | Imprint | This part of the site doesn't use cookies.