@@ 665-675 (lines=11) @@ | ||
662 | /** |
|
663 | * @covers \eZ\Publish\Core\Persistence\Legacy\Content\Gateway\DoctrineDatabase::listVersionNumbers |
|
664 | */ |
|
665 | public function testListVersionNumbers() |
|
666 | { |
|
667 | $this->insertDatabaseFixture( |
|
668 | __DIR__ . '/../_fixtures/contentobjects.php' |
|
669 | ); |
|
670 | ||
671 | $gateway = $this->getDatabaseGateway(); |
|
672 | $res = $gateway->listVersionNumbers(226); |
|
673 | ||
674 | $this->assertEquals([1, 2], $res); |
|
675 | } |
|
676 | ||
677 | /** |
|
678 | * @covers \eZ\Publish\Core\Persistence\Legacy\Content\Gateway\DoctrineDatabase::listVersionsForUser |
|
@@ 829-842 (lines=14) @@ | ||
826 | * @covers \eZ\Publish\Core\Persistence\Legacy\Content\Gateway\DoctrineDatabase::load |
|
827 | * @covers \eZ\Publish\Core\Persistence\Legacy\Content\Gateway\DoctrineDatabase\QueryBuilder |
|
828 | */ |
|
829 | public function testLoadNonExistentTranslation() |
|
830 | { |
|
831 | $this->insertDatabaseFixture( |
|
832 | __DIR__ . '/../_fixtures/contentobjects.php' |
|
833 | ); |
|
834 | ||
835 | $gateway = $this->getDatabaseGateway(); |
|
836 | $res = $gateway->load(226, 2, ['de-DE']); |
|
837 | ||
838 | $this->assertCount( |
|
839 | 0, |
|
840 | $res |
|
841 | ); |
|
842 | } |
|
843 | ||
844 | /** |
|
845 | * Asserts that $columnKey in $actualRows exactly contains $expectedValues. |
|
@@ 875-887 (lines=13) @@ | ||
872 | /** |
|
873 | * @covers \eZ\Publish\Core\Persistence\Legacy\Content\Gateway\DoctrineDatabase::getAllLocationIds |
|
874 | */ |
|
875 | public function testGetAllLocationIds() |
|
876 | { |
|
877 | $this->insertDatabaseFixture( |
|
878 | __DIR__ . '/../_fixtures/contentobjects.php' |
|
879 | ); |
|
880 | ||
881 | $gateway = $this->getDatabaseGateway(); |
|
882 | ||
883 | $this->assertEquals( |
|
884 | [228], |
|
885 | $gateway->getAllLocationIds(226) |
|
886 | ); |
|
887 | } |
|
888 | ||
889 | /** |
|
890 | * @covers \eZ\Publish\Core\Persistence\Legacy\Content\Gateway\DoctrineDatabase::getFieldIdsByType |