Skip to content

Commit 073c244

Browse files
committed
refactored to remove entity const
1 parent 91f4be6 commit 073c244

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

tests/Fixtures/ResetPasswordRequestRepositoryTestFixture.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
use SymfonyCasts\Bundle\ResetPassword\Model\ResetPasswordRequestInterface;
1515
use SymfonyCasts\Bundle\ResetPassword\Persistence\Repository\ResetPasswordRequestRepositoryTrait;
1616
use SymfonyCasts\Bundle\ResetPassword\Persistence\ResetPasswordRequestRepositoryInterface;
17+
use SymfonyCasts\Bundle\ResetPassword\Tests\Fixtures\Entity\ResetPasswordRequestTestFixture;
1718

1819
/**
1920
* @author Jesse Rushlow <[email protected]>
@@ -25,7 +26,6 @@ final class ResetPasswordRequestRepositoryTestFixture implements ResetPasswordRe
2526
{
2627
use ResetPasswordRequestRepositoryTrait;
2728

28-
private const ENTITY = \SymfonyCasts\Bundle\ResetPassword\Tests\Fixtures\Entity\ResetPasswordRequestTestFixture::class;
2929
private $manager;
3030

3131
public function __construct(EntityManagerInterface $manager = null)
@@ -43,14 +43,14 @@ public function createResetPasswordRequest(
4343

4444
public function findOneBy(array $criteria)
4545
{
46-
$persister = $this->manager->getUnitOfWork()->getEntityPersister(self::ENTITY);
46+
$persister = $this->manager->getUnitOfWork()->getEntityPersister(ResetPasswordRequestTestFixture::class);
4747

4848
return $persister->load($criteria);
4949
}
5050

5151
public function findAll()
5252
{
53-
$persister = $this->manager->getUnitOfWork()->getEntityPersister(self::ENTITY);
53+
$persister = $this->manager->getUnitOfWork()->getEntityPersister(ResetPasswordRequestTestFixture::class);
5454

5555
return $persister->loadAll();
5656
}
@@ -64,7 +64,7 @@ private function createQueryBuilder($alias, $indexBy = null): QueryBuilder
6464
{
6565
return $this->manager->createQueryBuilder()
6666
->select($alias)
67-
->from(self::ENTITY, $alias, $indexBy)
67+
->from(ResetPasswordRequestTestFixture::class, $alias, $indexBy)
6868
;
6969
}
7070
}

0 commit comments

Comments
 (0)