protected function setUp() { parent::setUp(); $this->am = $this->getMock('Assetic\\AssetManager'); $this->fm = $this->getMock('Assetic\\FilterManager'); $factory = new AssetFactory(__DIR__ . '/templates'); $factory->setAssetManager($this->am); $factory->setFilterManager($this->fm); $this->engine->addExtension(new AsseticExtensionForTest($factory)); $this->loader = new SmartyFormulaLoader($this->engine); }
protected function setUp() { parent::setUp(); if (!class_exists('Assetic\\AssetManager')) { $this->markTestSkipped('Assetic is not available.'); } $templatesDir = realpath(__DIR__ . '/../Assetic/templates'); $this->am = $this->getMock('Assetic\\AssetManager'); $this->fm = $this->getMock('Assetic\\FilterManager'); $this->valueSupplier = $this->getMock('Assetic\\ValueSupplierInterface'); $this->factory = new AssetFactory($templatesDir); $this->factory->setAssetManager($this->am); $this->factory->setFilterManager($this->fm); $this->engine->setTemplateDir($templatesDir); $this->engine->addExtension(new AsseticExtensionForTest($this->factory, false, $this->valueSupplier)); }
protected function setUp() { parent::setUp(); $templatesDir = __DIR__ . '/templates/assets'; $this->engine->setTemplateDir($templatesDir); }
/** * @since 0.2.0 * @author Vítor Brandão <*****@*****.**> */ protected function createContainer(array $data = array()) { $container = parent::createContainer($data); $request = new Request(); $container->set('request', $request); return $container; }