Removing useless imports
This commit is contained in:
parent
cbb0c1bd04
commit
d51235f200
@ -5,7 +5,7 @@ namespace Doctrine\Performance\Hydration;
|
|||||||
use Doctrine\Common\Persistence\ObjectRepository;
|
use Doctrine\Common\Persistence\ObjectRepository;
|
||||||
use Doctrine\ORM\EntityManagerInterface;
|
use Doctrine\ORM\EntityManagerInterface;
|
||||||
use Doctrine\Performance\EntityManagerFactory;
|
use Doctrine\Performance\EntityManagerFactory;
|
||||||
use Doctrine\Tests\Models\CMS\CmsUser;
|
use Doctrine\Tests\Models\CMS;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @BeforeMethods({"init"})
|
* @BeforeMethods({"init"})
|
||||||
@ -25,18 +25,18 @@ final class SimpleHydrationBench
|
|||||||
public function init()
|
public function init()
|
||||||
{
|
{
|
||||||
$this->entityManager = EntityManagerFactory::getEntityManager([
|
$this->entityManager = EntityManagerFactory::getEntityManager([
|
||||||
\Doctrine\Tests\Models\CMS\CmsUser::class,
|
CMS\CmsUser::class,
|
||||||
\Doctrine\Tests\Models\CMS\CmsPhonenumber::class,
|
CMS\CmsPhonenumber::class,
|
||||||
\Doctrine\Tests\Models\CMS\CmsAddress::class,
|
CMS\CmsAddress::class,
|
||||||
\Doctrine\Tests\Models\CMS\CmsEmail::class,
|
CMS\CmsEmail::class,
|
||||||
\Doctrine\Tests\Models\CMS\CmsGroup::class,
|
CMS\CmsGroup::class,
|
||||||
\Doctrine\Tests\Models\CMS\CmsTag::class,
|
CMS\CmsTag::class,
|
||||||
\Doctrine\Tests\Models\CMS\CmsArticle::class,
|
CMS\CmsArticle::class,
|
||||||
\Doctrine\Tests\Models\CMS\CmsComment::class,
|
CMS\CmsComment::class,
|
||||||
]);
|
]);
|
||||||
|
|
||||||
for ($i = 2; $i < 10000; ++$i) {
|
for ($i = 2; $i < 10000; ++$i) {
|
||||||
$user = new CmsUser();
|
$user = new CMS\CmsUser();
|
||||||
|
|
||||||
$user->status = 'developer';
|
$user->status = 'developer';
|
||||||
$user->username = 'jwage' . $i;
|
$user->username = 'jwage' . $i;
|
||||||
@ -48,7 +48,7 @@ final class SimpleHydrationBench
|
|||||||
$this->entityManager->flush();
|
$this->entityManager->flush();
|
||||||
$this->entityManager->clear();
|
$this->entityManager->clear();
|
||||||
|
|
||||||
$this->repository = $this->entityManager->getRepository(CmsUser::class);
|
$this->repository = $this->entityManager->getRepository(CMS\CmsUser::class);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function benchHydration()
|
public function benchHydration()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user