Skip to content

Fix getting single custom role through graphQL

Jarka Košanová requested to merge 437119-fix-getting-instance-mr into master

What does this MR do and why?

It fixes retrieving a single custom role through graphQL endpoint.

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

How to set up and validate locally

  1. Make sure you are not on SaaS
  2. Create a new instance custom role, eg. using graphQL
mutation {
  memberRoleCreate(input: {
    name: "Instance role", 
    description: "This is a new test role",
    readCode: true,
    readVulnerability: true,
    baseAccessLevel: GUEST
  }) {
    errors
    memberRole {
      id
      name
    }
  }
}
  1. Verify you can retrieve this custom role using graphQL:
{
  memberRole(id: "gid://gitlab/MemberRole/3") {
    id
    name
    readVulnerability
    readCode
    adminGroupMember
  }
}

Related to #437119 (closed)

Edited by Jarka Košanová

Merge request reports

Loading