summaryrefslogtreecommitdiff
path: root/src/testing/testing_api_cmd_patch_webhook.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/testing/testing_api_cmd_patch_webhook.c')
-rw-r--r--src/testing/testing_api_cmd_patch_webhook.c37
1 files changed, 19 insertions, 18 deletions
diff --git a/src/testing/testing_api_cmd_patch_webhook.c b/src/testing/testing_api_cmd_patch_webhook.c
index a2fea433..0b066371 100644
--- a/src/testing/testing_api_cmd_patch_webhook.c
+++ b/src/testing/testing_api_cmd_patch_webhook.c
@@ -147,16 +147,17 @@ patch_webhook_run (void *cls,
struct PatchWebhookState *pis = cls;
pis->is = is;
- pis->iph = TALER_MERCHANT_webhook_patch (is->ctx,
- pis->merchant_url,
- pis->webhook_id,
- pis->event_type,
- pis->url,
- pis->http_method,
- pis->header_template,
- pis->body_template,
- &patch_webhook_cb,
- pis);
+ pis->iph = TALER_MERCHANT_webhook_patch (
+ TALER_TESTING_interpreter_get_context (is),
+ pis->merchant_url,
+ pis->webhook_id,
+ pis->event_type,
+ pis->url,
+ pis->http_method,
+ pis->header_template,
+ pis->body_template,
+ &patch_webhook_cb,
+ pis);
GNUNET_assert (NULL != pis->iph);
}
@@ -179,12 +180,12 @@ patch_webhook_traits (void *cls,
{
struct PatchWebhookState *pws = cls;
struct TALER_TESTING_Trait traits[] = {
- TALER_TESTING_make_trait_event_type (&pws->event_type),
- TALER_TESTING_make_trait_url (&pws->url),
- TALER_TESTING_make_trait_http_method (&pws->http_method),
- TALER_TESTING_make_trait_header_template (&pws->header_template),
- TALER_TESTING_make_trait_body_template (&pws->body_template),
- TALER_TESTING_make_trait_webhook_id (&pws->webhook_id),
+ TALER_TESTING_make_trait_event_type (pws->event_type),
+ TALER_TESTING_make_trait_url (pws->url),
+ TALER_TESTING_make_trait_http_method (pws->http_method),
+ TALER_TESTING_make_trait_header_template (pws->header_template),
+ TALER_TESTING_make_trait_body_template (pws->body_template),
+ TALER_TESTING_make_trait_webhook_id (pws->webhook_id),
TALER_TESTING_trait_end (),
};
@@ -239,8 +240,8 @@ TALER_TESTING_cmd_merchant_patch_webhook (
pis->event_type = event_type;
pis->url = url;
pis->http_method = http_method;
- pis->header_template = header_template;
- pis->body_template = body_template;
+ pis->header_template = (NULL == header_template) ? NULL : header_template;
+ pis->body_template = (NULL == body_template) ? NULL : body_template;
{
struct TALER_TESTING_Command cmd = {
.cls = pis,