Code Duplication    Length = 14-14 lines in 2 locations

eZ/Publish/Core/Persistence/Legacy/Tests/Content/TreeHandlerTest.php 1 location

@@ 460-473 (lines=14) @@
457
     *
458
     * @return \PHPUnit_Framework_MockObject_MockObject|\eZ\Publish\Core\Persistence\Legacy\Content\FieldHandler
459
     */
460
    protected function getFieldHandlerMock()
461
    {
462
        if (!isset($this->fieldHandlerMock)) {
463
            $this->fieldHandlerMock = $this->getMock(
464
                'eZ\\Publish\\Core\\Persistence\\Legacy\\Content\\FieldHandler',
465
                [],
466
                [],
467
                '',
468
                false
469
            );
470
        }
471
472
        return $this->fieldHandlerMock;
473
    }
474
475
    /**
476
     * @param array $methods

eZ/Publish/Core/Persistence/Legacy/Tests/Content/ContentHandlerTest.php 1 location

@@ 1502-1515 (lines=14) @@
1499
     *
1500
     * @return \eZ\Publish\Core\Persistence\Legacy\Content\FieldHandler
1501
     */
1502
    protected function getFieldHandlerMock()
1503
    {
1504
        if (!isset($this->fieldHandlerMock)) {
1505
            $this->fieldHandlerMock = $this->getMock(
1506
                'eZ\\Publish\\Core\\Persistence\\Legacy\\Content\\FieldHandler',
1507
                [],
1508
                [],
1509
                '',
1510
                false
1511
            );
1512
        }
1513
1514
        return $this->fieldHandlerMock;
1515
    }
1516
1517
    /**
1518
     * Returns a Mapper mock.