Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Always send 'checks' field when creating branch protection #2468

Merged
merged 3 commits into from Sep 19, 2022

Conversation

luisdavim
Copy link
Contributor

Fixes #2467

Copy link
Collaborator

@gmlewis gmlewis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you, @luisdavim .
Could you please add a unit test demonstrating that this field is indeed sent when empty as a means of documenting that we explicitly wish to send it in all cases?

@codecov
Copy link

codecov bot commented Sep 17, 2022

Codecov Report

Merging #2468 (8e6ca17) into master (642c343) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master    #2468   +/-   ##
=======================================
  Coverage   98.03%   98.03%           
=======================================
  Files         122      122           
  Lines       10695    10695           
=======================================
  Hits        10485    10485           
  Misses        144      144           
  Partials       66       66           
Impacted Files Coverage Δ
github/repos.go 98.67% <ø> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

…anches to be up to date before merging and no checks

Signed-off-by: Luis Davim <luis.davim@sendoso.com>
@luisdavim
Copy link
Contributor Author

luisdavim commented Sep 17, 2022

@gmlewis I've added a new test case for this scenario, where we set strict branch protection checks with an empty set of checks.

…ction checks

Signed-off-by: Luis Davim <luis.davim@sendoso.com>
@gmlewis gmlewis added the NeedsReview PR is awaiting a review before merging. label Sep 18, 2022
Copy link
Collaborator

@gmlewis gmlewis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you, @luisdavim !
LGTM.

Awaiting second LGTM+Approval from any other contributor to this repo before merging.

Copy link
Contributor

@raynigon raynigon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@gmlewis
Copy link
Collaborator

gmlewis commented Sep 19, 2022

Thank you, @raynigon !
Merging.

@gmlewis gmlewis changed the title fix: invalid request when creating branch protection Always send 'checks' field when creating branch protection Sep 19, 2022
@gmlewis gmlewis merged commit 23a2636 into google:master Sep 19, 2022
@luisdavim luisdavim deleted the fix_2467 branch September 19, 2022 10:38
@gmlewis gmlewis removed the NeedsReview PR is awaiting a review before merging. label Sep 19, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Error when creating branch protection
3 participants