|
14 | 14 | use Doctrine\ORM\Tools\SchemaTool;
|
15 | 15 | use Doctrine\Tests\Models\DataTransferObjects\DtoWithArrayOfEnums;
|
16 | 16 | use Doctrine\Tests\Models\DataTransferObjects\DtoWithEnum;
|
17 |
| -use Doctrine\Tests\Models\Enums\BookWithGenre; |
18 | 17 | use Doctrine\Tests\Models\Enums\BookCategory;
|
19 | 18 | use Doctrine\Tests\Models\Enums\BookGenre;
|
| 19 | +use Doctrine\Tests\Models\Enums\BookWithGenre; |
20 | 20 | use Doctrine\Tests\Models\Enums\Card;
|
21 | 21 | use Doctrine\Tests\Models\Enums\CardWithDefault;
|
22 | 22 | use Doctrine\Tests\Models\Enums\CardWithNullable;
|
|
28 | 28 | use Doctrine\Tests\Models\Enums\TypedCard;
|
29 | 29 | use Doctrine\Tests\Models\Enums\Unit;
|
30 | 30 | use Doctrine\Tests\OrmFunctionalTestCase;
|
| 31 | +use Generator; |
31 | 32 |
|
32 | 33 | use function dirname;
|
33 | 34 | use function sprintf;
|
@@ -540,10 +541,10 @@ public function testEnumCollectionMatchingOnOneToMany(Comparison $comparison): v
|
540 | 541 |
|
541 | 542 | $library = new Library();
|
542 | 543 |
|
543 |
| - $fictionBook = new BookWithGenre(BookGenre::FICTION); |
| 544 | + $fictionBook = new BookWithGenre(BookGenre::FICTION); |
544 | 545 | $fictionBook->library = $library;
|
545 | 546 |
|
546 |
| - $nonfictionBook = new BookWithGenre(BookGenre::NON_FICTION); |
| 547 | + $nonfictionBook = new BookWithGenre(BookGenre::NON_FICTION); |
547 | 548 | $nonfictionBook->library = $library;
|
548 | 549 |
|
549 | 550 | $this->_em->persist($library);
|
@@ -593,7 +594,7 @@ public function testEnumCollectionMatchingOnManyToMany(Comparison $comparison):
|
593 | 594 | self::assertSame($nonfictionBook->id, $result[0]->id);
|
594 | 595 | }
|
595 | 596 |
|
596 |
| - public function provideGenreMatchingExpressions(): \Generator |
| 597 | + public function provideGenreMatchingExpressions(): Generator |
597 | 598 | {
|
598 | 599 | yield [Criteria::expr()->eq('genre', BookGenre::NON_FICTION)];
|
599 | 600 | yield [Criteria::expr()->in('genre', [BookGenre::NON_FICTION])];
|
|
0 commit comments