Code Duplication    Length = 14-15 lines in 3 locations

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

@@ 2480-2494 (lines=15) @@
2477
     * @covers \eZ\Publish\Core\Persistence\Legacy\Content\UrlAlias\Handler::listGlobalURLAliases
2478
     * @depends testLookupResourceUrlAlias
2479
     */
2480
    public function testListGlobalURLAliasesWithLanguageCode()
2481
    {
2482
        $handler = $this->getHandler();
2483
        $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_resource.php');
2484
2485
        $globalAliasList = $handler->listGlobalURLAliases('eng-GB');
2486
2487
        self::assertEquals(
2488
            [
2489
                $handler->lookup('is-alive'),
2490
                $handler->lookup('nop-element/search'),
2491
            ],
2492
            $globalAliasList
2493
        );
2494
    }
2495
2496
    /**
2497
     * Test for the listGlobalURLAliases() method.
@@ 2877-2890 (lines=14) @@
2874
     *
2875
     * @covers \eZ\Publish\Core\Persistence\Legacy\Content\UrlAlias\Handler::locationCopied
2876
     */
2877
    public function testLocationCopiedCopiedLocationAliasIsValid()
2878
    {
2879
        $handler = $this->getHandler();
2880
        $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_copy.php');
2881
2882
        $urlAlias = $handler->lookup('move-this');
2883
2884
        $handler->locationCopied(4, 400, 3);
2885
2886
        self::assertEquals(
2887
            $urlAlias,
2888
            $handler->lookup('move-this')
2889
        );
2890
    }
2891
2892
    /**
2893
     * Test for the locationCopied() method.
@@ 2897-2910 (lines=14) @@
2894
     *
2895
     * @covers \eZ\Publish\Core\Persistence\Legacy\Content\UrlAlias\Handler::locationCopied
2896
     */
2897
    public function testLocationCopiedCopiedSubtreeIsValid()
2898
    {
2899
        $handler = $this->getHandler();
2900
        $this->insertDatabaseFixture(__DIR__ . '/_fixtures/urlaliases_copy.php');
2901
2902
        $urlAlias = $handler->lookup('move-this/sub1/sub2');
2903
2904
        $handler->locationCopied(4, 400, 3);
2905
2906
        self::assertEquals(
2907
            $urlAlias,
2908
            $handler->lookup('move-this/sub1/sub2')
2909
        );
2910
    }
2911
2912
    /**
2913
     * Test for the locationCopied() method.