setUpUnitServices(); } /** * @covers ::create * @covers ::__construct */ public function testBlazyManagerCreate() { $container = $this->getMock(ContainerInterface::class); $exception = ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE; $map = [ ['entity_type.manager', $exception, $this->entityTypeManager], ['module_handler', $exception, $this->moduleHandler], ['renderer', $exception, $this->renderer], ['config.factory', $exception, $this->configFactory], ['cache.default', $exception, $this->cache], ]; $container->expects($this->any()) ->method('get') ->willReturnMap($map); $blazyManager = BlazyManager::create($container); $this->assertInstanceOf(BlazyManager::class, $blazyManager); } }