eZ\Publish\Core\REST\Server\Tests\Input\Parser\ContentCreateTest::getContentServiceMock PHP Method

getContentServiceMock() protected method

Get the content service mock object.
protected getContentServiceMock ( ) : eZ\Publish\API\Repository\ContentService
return eZ\Publish\API\Repository\ContentService
    protected function getContentServiceMock()
    {
        $contentServiceMock = $this->getMock('eZ\\Publish\\Core\\Repository\\ContentService', array(), array(), '', false);
        $contentType = $this->getContentType();
        $contentServiceMock->expects($this->any())->method('newContentCreateStruct')->with($this->equalTo($contentType), $this->equalTo('eng-US'))->will($this->returnValue(new ContentCreateStruct(array('contentType' => $contentType, 'mainLanguageCode' => 'eng-US'))));
        return $contentServiceMock;
    }