protected function getRoleServiceMock()
{
$roleServiceMock = $this->getMock('eZ\\Publish\\Core\\Repository\\RoleService', array(), array(), '', false);
$roleServiceMock->expects($this->any())->method('newPolicyCreateStruct')->with($this->equalTo('content'), $this->equalTo('delete'))->will($this->returnValue(new PolicyCreateStruct(array('module' => 'content', 'function' => 'delete'))));
return $roleServiceMock;
}