Skip to content

fix: return a WebhookTestResultItem from webhooks.test - #1929

Open
ranjithguggilla wants to merge 1 commit into
tableau:developmentfrom
ranjithguggilla:fix/555-webhook-test-result
Open

ranjithguggilla wants to merge 1 commit into
tableau:developmentfrom
ranjithguggilla:fix/555-webhook-test-result

Conversation

@ranjithguggilla

Copy link
Copy Markdown

Closes #555

Motivation

webhooks.test returned the raw HTTP response. The Test Webhook method returns a webhookTestResult element with the webhook id, the destination's HTTP status, and the destination's body. Chris Shin asked for that to be parsed into an object.

Behavior change

webhooks.test now returns a WebhookTestResultItem (id, status, body) instead of the response object. Callers that read the raw response need to use those attributes.

Test plan

test_test feeds the documented response XML and checks the id, status 200, and body. The rest of test/test_webhook.py passes.

Not covered: a call against a live webhook destination.

webhooks.test handed back the raw response. It now parses webhookTestResult
into the destination id, HTTP status, and body.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

create a new WebhookTestResultItem, and return that rather than returning the raw http response

1 participant