protected function setUp() { $config = new \Doctrine\ODM\MongoDB\Configuration(); $config->setHydratorDir(sys_get_temp_dir()); $config->setHydratorNamespace('Hydrators'); $config->setProxyDir(sys_get_temp_dir()); $config->setProxyNamespace('Proxies'); $locatorXml = new SymfonyFileLocator(array(__DIR__ . '/../../../../../lib/Vespolina/Action/Mapping' => 'Vespolina\\Entity\\Action'), '.mongodb.xml'); $xmlDriver = new XmlDriver($locatorXml); $config->setMetadataDriverImpl($xmlDriver); $config->setMetadataCacheImpl(new ArrayCache()); $config->setAutoGenerateProxyClasses(true); $doctrineODM = \Doctrine\ODM\MongoDB\DocumentManager::create(null, $config); $this->actionGateway = new ActionDoctrineMongoDBGateway($doctrineODM, 'Vespolina\\Entity\\Action\\Action'); parent::setUp(); }
protected function setUp() { $this->actionGateway = new ActionMemoryGateway(); parent::setUp(); }