-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
[feat]: add methods for app hook deliveries #1620
Conversation
d7efeec
to
65c467d
Compare
f5ebd7c
to
f3d13b6
Compare
spec/octokit/client/apps_spec.rb
Outdated
describe '.list_app_hook_deliveries' do | ||
it 'lists hook deliveries for an app' do | ||
response = @jwt_client.list_app_hook_deliveries | ||
expect(response).to be_kind_of(Array) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What do you think about expanding the list of assertions here to include a total count check?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, that sounds good to me!
I've got to admit that I'm still a bit confused about how to successfully record a new VCR cassette, which is needed for the tests. Do I need to provide some of the ENV variables listed in the table in the README and run the specs with those variables?
Edit: Figured it out 😁
# @see https://developer.github.com/v3/apps/#redeliver-a-delivery-for-an-app-webhook | ||
# | ||
# @return [Boolean] Success | ||
def deliver_app_hook(delivery_id, options = {}) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you have thoughts on how this might be tested?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, just added in a spec for this endpoint as well. Similar to some of the specs for endpoints the delete resources, the only real thing to test for here is a truthy response
@kfcampbell, friendly bump on this one, I think I addressed all your comments |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @SebRollen for these changes! ❤️
Resolves #1619
Before the change?
After the change?
Pull request checklist
This is my first PR to Octokit and I wasn't able to get a test working using the JWT token, would appreciate some pointers here!
Does this introduce a breaking change?
Please see our docs on breaking changes to help!