protected function getContentTypeServiceMock() { $contentTypeServiceMock = $this->getMock('eZ\\Publish\\Core\\Repository\\ContentTypeService', array(), array(), '', false); $contentTypeServiceMock->expects($this->any())->method('newContentTypeUpdateStruct')->will($this->returnValue(new ContentTypeUpdateStruct())); return $contentTypeServiceMock; }