test(whatsapp): update facebook_api_client spec for calls subscription

Mirrors the subscribed_fields change in 567631b — the webmock body matcher
needs `calls` so the override-failure stub actually fires.
This commit is contained in:
Tanmay Deep Sharma
2026-05-05 18:11:01 +07:00
parent 9e012e923b
commit 23ccec3ebc
@@ -177,7 +177,7 @@ describe Whatsapp::FacebookApiClient do
.with(
headers: { 'Authorization' => "Bearer #{access_token}", 'Content-Type' => 'application/json' },
body: { override_callback_uri: callback_url, verify_token: verify_token,
subscribed_fields: %w[messages smb_message_echoes] }.to_json
subscribed_fields: %w[messages smb_message_echoes calls] }.to_json
)
.to_return(
status: 200,
@@ -224,7 +224,7 @@ describe Whatsapp::FacebookApiClient do
.with(
headers: { 'Authorization' => "Bearer #{access_token}", 'Content-Type' => 'application/json' },
body: { override_callback_uri: callback_url, verify_token: verify_token,
subscribed_fields: %w[messages smb_message_echoes] }.to_json
subscribed_fields: %w[messages smb_message_echoes calls] }.to_json
)
.to_return(status: 400, body: { error: 'Webhook callback override failed' }.to_json)
end