Code Duplication    Length = 12-14 lines in 2 locations

eZ/Publish/Core/Persistence/Legacy/Tests/Content/ContentHandlerTest.php 2 locations

@@ 545-558 (lines=14) @@
542
     * @covers \eZ\Publish\Core\Persistence\Legacy\Content\Handler::load
543
     * @expectedException \eZ\Publish\Core\Base\Exceptions\NotFoundException
544
     */
545
    public function testLoadErrorNotFound()
546
    {
547
        $handler = $this->getContentHandler();
548
549
        $gatewayMock = $this->getGatewayMock();
550
551
        $gatewayMock->expects($this->once())
552
            ->method('load')
553
            ->will(
554
                $this->returnValue([])
555
            );
556
557
        $result = $handler->load(23, 2, ['eng-GB']);
558
    }
559
560
    /**
561
     * Returns a Content for {@link testCreateDraftFromVersion()}.
@@ 1374-1385 (lines=12) @@
1371
     * @covers \eZ\Publish\Core\Persistence\Legacy\Content\Handler::copy
1372
     * @expectedException \eZ\Publish\Core\Base\Exceptions\NotFoundException
1373
     */
1374
    public function testCopyThrowsNotFoundExceptionVersionNotFound()
1375
    {
1376
        $handler = $this->getContentHandler();
1377
1378
        $gatewayMock = $this->getGatewayMock();
1379
        $gatewayMock->expects($this->once())
1380
            ->method('load')
1381
            ->with($this->equalTo(23, 32))
1382
            ->will($this->returnValue([]));
1383
1384
        $result = $handler->copy(23, 32);
1385
    }
1386
1387
    /**
1388
     * @covers \eZ\Publish\Core\Persistence\Legacy\Content\Handler::setStatus