Skip to content

Convert branch protection response to hash in Github Import

What does this MR do and why?

This merge request is part of a series of changes to convert Octokit returned objects into a hash before using it in the codebase in order to rely less on Sawyer::Resource objects

This change converts the branch_protection method, which was added recently to the client, into a hash.

The code using this method was already converted to use the hash notation in !98224 (merged)

Related to: https://gitlab.com/gitlab-org/gitlab/-/issues/372473

Screenshots or screen recordings

Branch-protection

How to set up and validate locally

  1. At Github, setup the branch protection configuration of a project
  2. At Gitlab, go to projects, new project, import from Github
  3. Select the project to import
  4. Check if the branch protection configuration was migrated

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Rodrigo Tomonari

Merge request reports

Loading