[DoctrineBundle] removed old code
This commit is contained in:
parent
d16a708cc8
commit
0b7a19e6fd
@ -11,8 +11,6 @@
|
|||||||
|
|
||||||
namespace Symfony\Bundle\DoctrineBundle\Tests;
|
namespace Symfony\Bundle\DoctrineBundle\Tests;
|
||||||
|
|
||||||
use Symfony\Bundle\DoctrineBundle\Annotations\IndexedReader;
|
|
||||||
|
|
||||||
use Doctrine\Common\Annotations\AnnotationReader;
|
use Doctrine\Common\Annotations\AnnotationReader;
|
||||||
use Doctrine\ORM\Mapping\Driver\AnnotationDriver;
|
use Doctrine\ORM\Mapping\Driver\AnnotationDriver;
|
||||||
use Doctrine\ORM\EntityManager;
|
use Doctrine\ORM\EntityManager;
|
||||||
@ -31,27 +29,6 @@ class TestCase extends \PHPUnit_Framework_TestCase
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @return EntityManager
|
|
||||||
*/
|
|
||||||
protected function createTestEntityManager($paths = array())
|
|
||||||
{
|
|
||||||
$config = new \Doctrine\ORM\Configuration();
|
|
||||||
$config->setAutoGenerateProxyClasses(true);
|
|
||||||
$config->setProxyDir(\sys_get_temp_dir());
|
|
||||||
$config->setProxyNamespace('SymfonyTests\Doctrine');
|
|
||||||
$config->setMetadataDriverImpl(new AnnotationDriver(new IndexedReader(new AnnotationReader()), $paths));
|
|
||||||
$config->setQueryCacheImpl(new \Doctrine\Common\Cache\ArrayCache());
|
|
||||||
$config->setMetadataCacheImpl(new \Doctrine\Common\Cache\ArrayCache());
|
|
||||||
|
|
||||||
$params = array(
|
|
||||||
'driver' => 'pdo_sqlite',
|
|
||||||
'memory' => true,
|
|
||||||
);
|
|
||||||
|
|
||||||
return EntityManager::create($params, $config);
|
|
||||||
}
|
|
||||||
|
|
||||||
public function createYamlBundleTestContainer()
|
public function createYamlBundleTestContainer()
|
||||||
{
|
{
|
||||||
$container = new ContainerBuilder(new ParameterBag(array(
|
$container = new ContainerBuilder(new ParameterBag(array(
|
||||||
|
Reference in New Issue
Block a user