Code Duplication    Length = 14-15 lines in 3 locations

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

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