protected function setUp() { $this->container = new ContainerBuilder(); $this->extension = new OpenClassroomsCacheExtension(); $this->container->registerExtension($this->extension); $this->container->loadFromExtension('open_classrooms_cache'); $bundle = new OpenClassroomsCacheBundle(); $bundle->build($this->container); $this->container->setParameter('openclassrooms.cache.cache_provider_builder.class', 'OpenClassrooms\\Bundle\\CacheBundle\\Tests\\Cache\\CacheProviderBuilderMock'); $this->loader = new YamlFileLoader($this->container, new FileLocator(__DIR__ . '/Fixtures/Yaml/')); }
protected function initCacheBundle() { $cacheExtension = new OpenClassroomsCacheExtension(); $this->container->registerExtension($cacheExtension); $this->container->loadFromExtension('open_classrooms_cache'); $cacheBundle = new OpenClassroomsCacheBundle(); $cacheBundle->build($this->container); }