Code Duplication    Length = 27-27 lines in 2 locations

eZ/Publish/Core/Search/Legacy/Tests/Content/HandlerContentSortTest.php 2 locations

@@ 250-276 (lines=27) @@
247
        );
248
    }
249
250
    public function testSortDateModified()
251
    {
252
        $locator = $this->getContentSearchHandler();
253
254
        $result = $locator->findContent(
255
            new Query(
256
                array(
257
                    'filter' => new Criterion\SectionId(array(2)),
258
                    'offset' => 0,
259
                    'limit' => 10,
260
                    'sortClauses' => array(
261
                        new SortClause\DateModified(),
262
                    ),
263
                )
264
            )
265
        );
266
267
        $this->assertEquals(
268
            array(4, 12, 13, 42, 10, 14, 11, 226),
269
            array_map(
270
                function ($hit) {
271
                    return $hit->valueObject->id;
272
                },
273
                $result->searchHits
274
            )
275
        );
276
    }
277
278
    public function testSortDatePublished()
279
    {
@@ 278-304 (lines=27) @@
275
        );
276
    }
277
278
    public function testSortDatePublished()
279
    {
280
        $locator = $this->getContentSearchHandler();
281
282
        $result = $locator->findContent(
283
            new Query(
284
                array(
285
                    'filter' => new Criterion\SectionId(array(2)),
286
                    'offset' => 0,
287
                    'limit' => 10,
288
                    'sortClauses' => array(
289
                        new SortClause\DatePublished(),
290
                    ),
291
                )
292
            )
293
        );
294
295
        $this->assertEquals(
296
            array(4, 10, 11, 12, 13, 14, 226, 42),
297
            array_map(
298
                function ($hit) {
299
                    return $hit->valueObject->id;
300
                },
301
                $result->searchHits
302
            )
303
        );
304
    }
305
306
    public function testSortSectionIdentifier()
307
    {