FIX: Remove duplicate spec example (#24846)

This commit is contained in:
Selase Krakani 2023-12-12 12:48:23 +00:00 committed by GitHub
parent f6644a69c3
commit 90eff6f344
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 0 additions and 15 deletions

View File

@ -289,20 +289,5 @@ RSpec.describe Admin::WebHooksController do
expect(parsed_event["status"]).to eq(-1) expect(parsed_event["status"]).to eq(-1)
expect(parsed_event["response_body"]).to eq(nil) expect(parsed_event["response_body"]).to eq(nil)
end end
it "doesn't emit the web hook if the payload URL resolves to a blocked IP" do
FinalDestination::TestHelper.stub_to_fail do
post "/admin/api/web_hooks/#{web_hook.id}/events/#{web_hook_event.id}/redeliver.json"
end
expect(response.status).to eq(200)
parsed_event = response.parsed_body["web_hook_event"]
expect(parsed_event["id"]).to eq(web_hook_event.id)
expect(parsed_event["response_headers"]).to eq(
{ error: I18n.t("webhooks.payload_url.blocked_or_internal") }.to_json,
)
expect(parsed_event["status"]).to eq(-1)
expect(parsed_event["response_body"]).to eq(nil)
end
end end
end end