Code Duplication    Length = 14-15 lines in 3 locations

eZ/Publish/Core/Persistence/Legacy/Tests/Content/UrlAlias/UrlAliasHandlerTest.php 3 locations

@@ 2431-2445 (lines=15) @@
2428
     * @covers \eZ\Publish\Core\Persistence\Legacy\Content\UrlAlias\Handler::listGlobalURLAliases
2429
     * @depends testLookupResourceUrlAlias
2430
     */
2431
    public function testListGlobalURLAliasesWithLanguageCode()
2432
    {
2433
        $handler = $this->getHandler();
2434
        $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_resource.php');
2435
2436
        $globalAliasList = $handler->listGlobalURLAliases('eng-GB');
2437
2438
        self::assertEquals(
2439
            [
2440
                $handler->lookup('is-alive'),
2441
                $handler->lookup('nop-element/search'),
2442
            ],
2443
            $globalAliasList
2444
        );
2445
    }
2446
2447
    /**
2448
     * Test for the listGlobalURLAliases() method.
@@ 2813-2826 (lines=14) @@
2810
     *
2811
     * @covers \eZ\Publish\Core\Persistence\Legacy\Content\UrlAlias\Handler::locationCopied
2812
     */
2813
    public function testLocationCopiedCopiedLocationAliasIsValid()
2814
    {
2815
        $handler = $this->getHandler();
2816
        $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_copy.php');
2817
2818
        $urlAlias = $handler->lookup('move-this');
2819
2820
        $handler->locationCopied(4, 400, 3);
2821
2822
        self::assertEquals(
2823
            $urlAlias,
2824
            $handler->lookup('move-this')
2825
        );
2826
    }
2827
2828
    /**
2829
     * Test for the locationCopied() method.
@@ 2833-2846 (lines=14) @@
2830
     *
2831
     * @covers \eZ\Publish\Core\Persistence\Legacy\Content\UrlAlias\Handler::locationCopied
2832
     */
2833
    public function testLocationCopiedCopiedSubtreeIsValid()
2834
    {
2835
        $handler = $this->getHandler();
2836
        $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_copy.php');
2837
2838
        $urlAlias = $handler->lookup('move-this/sub1/sub2');
2839
2840
        $handler->locationCopied(4, 400, 3);
2841
2842
        self::assertEquals(
2843
            $urlAlias,
2844
            $handler->lookup('move-this/sub1/sub2')
2845
        );
2846
    }
2847
2848
    /**
2849
     * Test for the locationCopied() method.