From 3fe5f04fbcefb33fe38866f1e3570ab21f944d25 Mon Sep 17 00:00:00 2001 From: Luis Ramos Date: Fri, 26 Mar 2021 23:04:32 +0000 Subject: [PATCH] Fix rspec syntax --- spec/controllers/stripe/webhooks_controller_spec.rb | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/spec/controllers/stripe/webhooks_controller_spec.rb b/spec/controllers/stripe/webhooks_controller_spec.rb index 437c10b55c..c8390ca6e1 100644 --- a/spec/controllers/stripe/webhooks_controller_spec.rb +++ b/spec/controllers/stripe/webhooks_controller_spec.rb @@ -21,7 +21,7 @@ describe Stripe::WebhooksController, type: :controller do end it "responds with a 400" do - post 'create', params + post 'create', params: params expect(response.status).to eq 400 end end @@ -32,7 +32,7 @@ describe Stripe::WebhooksController, type: :controller do end it "responds with a 401" do - post 'create', params + post 'create', params: params expect(response.status).to eq 401 end end @@ -50,7 +50,7 @@ describe Stripe::WebhooksController, type: :controller do before { allow(handler).to receive(:handle) { :garbage } } it "falls back to 200" do - post 'create', params + post 'create', params: params expect(response.status).to eq 200 end end @@ -59,7 +59,7 @@ describe Stripe::WebhooksController, type: :controller do before { allow(handler).to receive(:handle) { :unknown } } it "responds with 202" do - post 'create', params + post 'create', params: params expect(response.status).to eq 202 end end @@ -73,7 +73,7 @@ describe Stripe::WebhooksController, type: :controller do context "when the stripe_account id on the event does not match any known accounts" do it "doesn't delete any Stripe accounts, responds with 204" do - post 'create', params + post 'create', params: params expect(response.status).to eq 204 expect(StripeAccount.all).to include stripe_account end @@ -83,7 +83,7 @@ describe Stripe::WebhooksController, type: :controller do before { params["account"] = "webhook_id" } it "deletes Stripe accounts in response to a webhook" do - post 'create', params + post 'create', params: params expect(response.status).to eq 200 expect(StripeAccount.all).not_to include stripe_account end