-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
forge: ChangeIsMerged -> ChangesAreMerged (#399)
Replace ChangeIsMerged with a bulk ChangesAreMerged API that takes a list of ChangeIDs and returns a list of booleans in the same order. With this in place, we can change 'repo sync' to make a single request for all submitted branches instead of one request per branch. [skip changelog]: No user facing changes in this branch.
- Loading branch information
Showing
6 changed files
with
125 additions
and
55 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
37 changes: 37 additions & 0 deletions
37
internal/forge/github/testdata/fixtures/TestIntegration_Repository_ChangesAreMerged.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
--- | ||
version: 2 | ||
interactions: | ||
- id: 0 | ||
request: | ||
proto: HTTP/1.1 | ||
proto_major: 1 | ||
proto_minor: 1 | ||
content_length: 187 | ||
transfer_encoding: [] | ||
trailer: {} | ||
host: api.github.com | ||
remote_addr: "" | ||
request_uri: "" | ||
body: | | ||
{"query":"query($ids:[ID!]!){nodes(ids: $ids){... on PullRequest{merged}}}","variables":{"ids":["PR_kwDOJ2BQKs5ylEYu","PR_kwDOJ2BQKs56wX01","PR_kwDOJ2BQKs5xNeqO","PR_kwDOMVd0xs51N_9r"]}} | ||
form: {} | ||
headers: | ||
Content-Type: | ||
- application/json | ||
url: https://api.github.com/graphql | ||
method: POST | ||
response: | ||
proto: HTTP/2.0 | ||
proto_major: 2 | ||
proto_minor: 0 | ||
transfer_encoding: [] | ||
trailer: {} | ||
content_length: -1 | ||
uncompressed: true | ||
body: '{"data":{"nodes":[{"merged":true},{"merged":false},{"merged":true},{"merged":false}]}}' | ||
headers: | ||
Content-Type: | ||
- application/json; charset=utf-8 | ||
status: 200 OK | ||
code: 200 | ||
duration: 269.167291ms |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters