/** * {@inheritDoc} * * @return GlobPathStackResolver */ public function createService(ServiceLocatorInterface $serviceLocator) { $config = $serviceLocator->get('config'); $pathStackResolver = new GlobPathStackResolver(); $paths = array(); if (!empty($config['asset_manager']['resolver_configs']['paths'])) { $paths = $config['asset_manager']['resolver_configs']['paths']; } $pathStackResolver->addPaths($paths); return $pathStackResolver; }
public function testWillRefuseInvalidPath() { $resolver = new GlobPathStackResolver(); $this->setExpectedException('AssetManager\\Exception\\InvalidArgumentException'); $resolver->addPath(null); }