-
Notifications
You must be signed in to change notification settings - Fork 105
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Verify that the pull request head commit exists (#55)
Some GitHub APIs have a delay propagating information about new commits, particularly when the commits come from forks. While I believe the APIs we currently use are safe, if they are not, the policy should fail closed with an error instead of potentially failing open, as it does currently. Also reorganize some test data so that it is more consistent, making it easier for tests to pass this new check.
- Loading branch information
Showing
5 changed files
with
85 additions
and
36 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
- status: 200 | ||
body: | | ||
{ | ||
"number": 123, | ||
"user": { | ||
"login": "mhaypenny" | ||
}, | ||
"head": { | ||
"label": "testorg:test-branch", | ||
"ref": "test-branch", | ||
"sha": "e05fcae367230ee709313dd2720da527d178ce43", | ||
"repo": { | ||
"name": "testrepo", | ||
"full_name": "testorg/testrepo", | ||
"owner": { | ||
"login": "testorg" | ||
} | ||
} | ||
}, | ||
"base": { | ||
"label": "testorg:develop", | ||
"ref": "develop", | ||
"repo": { | ||
"name": "testrepo", | ||
"full_name": "testorg/testrepo", | ||
"owner": { | ||
"login": "testorg" | ||
} | ||
} | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
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