AssetManagerTest\Service\AliasPathStackResolverServiceFactoryTest::testCreateService PHP Method

testCreateService() public method

Mainly to avoid regressions
public testCreateService ( )
    public function testCreateService()
    {
        $serviceManager = new ServiceManager();
        $serviceManager->setService('config', array('asset_manager' => array('resolver_configs' => array('aliases' => array('alias1/' => 'path1', 'alias2/' => 'path2')))));
        $factory = new AliasPathStackResolverServiceFactory();
        /* @var $resolver AliasPathStackResolver */
        $resolver = $factory->createService($serviceManager);
        $reflectionClass = new \ReflectionClass(AliasPathStackResolver::class);
        $property = $reflectionClass->getProperty('aliases');
        $property->setAccessible(true);
        $this->assertSame(array('alias1/' => 'path1' . DIRECTORY_SEPARATOR, 'alias2/' => 'path2' . DIRECTORY_SEPARATOR), $property->getValue($resolver));
    }
AliasPathStackResolverServiceFactoryTest