@@ 538-549 (lines=12) @@ | ||
535 | $this->_em->getFilters()->enable("article_topic")->setParameter("topic", "Test1", DBALType::STRING); |
|
536 | } |
|
537 | ||
538 | public function testOneToMany_ExtraLazyCountWithFilter() |
|
539 | { |
|
540 | $this->loadLazyFixtureData(); |
|
541 | $user = $this->_em->find(CmsUser::class, $this->userId); |
|
542 | ||
543 | $this->assertFalse($user->articles->isInitialized()); |
|
544 | $this->assertEquals(2, count($user->articles)); |
|
545 | ||
546 | $this->useCMSArticleTopicFilter(); |
|
547 | ||
548 | $this->assertEquals(1, count($user->articles)); |
|
549 | } |
|
550 | ||
551 | public function testOneToMany_ExtraLazyContainsWithFilter() |
|
552 | { |
|
@@ 585-597 (lines=13) @@ | ||
582 | $this->_em->getFilters()->enable("group_prefix")->setParameter("prefix", "foo%", DBALType::STRING); |
|
583 | } |
|
584 | ||
585 | public function testManyToMany_ExtraLazyCountWithFilter() |
|
586 | { |
|
587 | $this->loadLazyFixtureData(); |
|
588 | ||
589 | $user = $this->_em->find(CmsUser::class, $this->userId2); |
|
590 | ||
591 | $this->assertFalse($user->groups->isInitialized()); |
|
592 | $this->assertEquals(2, count($user->groups)); |
|
593 | ||
594 | $this->useCMSGroupPrefixFilter(); |
|
595 | ||
596 | $this->assertEquals(1, count($user->groups)); |
|
597 | } |
|
598 | ||
599 | public function testManyToMany_ExtraLazyContainsWithFilter() |
|
600 | { |