Code Duplication    Length = 18-18 lines in 2 locations

eZ/Publish/API/Repository/Tests/SearchServiceTest.php 2 locations

@@ 1046-1063 (lines=18) @@
1043
    /**
1044
     * @expectedException \RuntimeException
1045
     */
1046
    public function testFindNoPerformCountException()
1047
    {
1048
        if (ltrim(get_class($this->getSetupFactory()), '\\') !== 'eZ\Publish\API\Repository\Tests\SetupFactory\Legacy') {
1049
            $this->markTestSkipped('Only applicable to Legacy/DB based search');
1050
        }
1051
1052
        $repository = $this->getRepository();
1053
        $searchService = $repository->getSearchService();
1054
1055
        $query = new Query();
1056
        $query->performCount = false;
1057
        $query->limit = 0;
1058
        $query->query = new Criterion\ContentTypeId(
1059
            array(4)
1060
        );
1061
1062
        $searchService->findContent($query);
1063
    }
1064
1065
    public function testFindLocationsNoPerformCount()
1066
    {
@@ 1094-1111 (lines=18) @@
1091
    /**
1092
     * @expectedException \RuntimeException
1093
     */
1094
    public function testFindLocationsNoPerformCountException()
1095
    {
1096
        if (ltrim(get_class($this->getSetupFactory()), '\\') !== 'eZ\Publish\API\Repository\Tests\SetupFactory\Legacy') {
1097
            $this->markTestSkipped('Only applicable to Legacy/DB based search');
1098
        }
1099
1100
        $repository = $this->getRepository();
1101
        $searchService = $repository->getSearchService();
1102
1103
        $query = new LocationQuery();
1104
        $query->performCount = false;
1105
        $query->limit = 0;
1106
        $query->query = new Criterion\ContentTypeId(
1107
            array(4)
1108
        );
1109
1110
        $searchService->findLocations($query);
1111
    }
1112
1113
    /**
1114
     * Create test Content with ezcountry field having multiple countries selected.