1
0
Fork 0
mirror of https://github.com/actions/toolkit synced 2025-05-09 16:43:02 +00:00

Correctly pull issue number for pull request review events (#311)

This commit is contained in:
Thomas Boop 2020-01-21 10:44:38 -05:00 committed by GitHub
parent 8b0300129f
commit a9175f3986
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 3 deletions

View file

@ -52,10 +52,11 @@ describe('@actions/context', () => {
})
})
it('works with pullRequest payloads', () => {
it('works with pull_request payloads', () => {
delete process.env.GITHUB_REPOSITORY
context.payload = {
pullRequest: {number: 2},
// eslint-disable-next-line @typescript-eslint/camelcase
pull_request: {number: 2},
repository: {owner: {login: 'user'}, name: 'test'}
}
expect(context.issue).toEqual({