Skip to content

Conversation

@zahiar
Copy link
Contributor

@zahiar zahiar commented Nov 15, 2021

This makes it easier for consumers of these methods to extract data easily without having to manually convert the interface into a matching struct.

Also added tests to cover the webhook functionality.

This makes it easier for consumers of these methods to extract data easily without having to manually convert the interface into a matching struct.

Also added tests to cover the webhook functionality.
@zahiar
Copy link
Contributor Author

zahiar commented Nov 15, 2021

New tests pass 😃

go test -v ./tests/webhooks_test.go
=== RUN   TestWebhook
=== RUN   TestWebhook/create
=== RUN   TestWebhook/get
=== RUN   TestWebhook/update
=== RUN   TestWebhook/delete
--- PASS: TestWebhook (3.15s)
    --- PASS: TestWebhook/create (1.24s)
    --- PASS: TestWebhook/get (0.64s)
    --- PASS: TestWebhook/update (0.64s)
    --- PASS: TestWebhook/delete (0.64s)
PASS
ok      command-line-arguments  3.376s

Url string `json:"url"`
Active bool `json:"active"`
Events []string `json:"events"` // EX) {'repo:push','issue:created',..} REF) https://goo.gl/VTj93b
Events []string `json:"events"` // EX: {'repo:push','issue:created',..} REF: https://bit.ly/3FjRHHu
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@ktrysmt The previous goo.gl shortlink referenced an old & now broken page, so I created a new shortlink to the new page.

Copy link
Owner

@ktrysmt ktrysmt left a comment

Choose a reason for hiding this comment

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

LGTM!

@ktrysmt ktrysmt merged commit ddab5c9 into ktrysmt:master Nov 17, 2021
@zahiar zahiar deleted the add-webhook-response-struct branch November 17, 2021 21:11
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.

2 participants