summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorAngel Perez <iAngel.p93@gmail.com>2018-12-13 13:31:46 +0100
committerAngel Perez <iAngel.p93@gmail.com>2018-12-13 13:31:46 +0100
commitf436098cf23dd23a62e4eaa65306b771acfa0814 (patch)
treec459b9a306e9000f6eec01690673e8c5d0b5106d /spec
parentf280ffb3afba61100d84c3f162efd5d7fdf40da1 (diff)
Set forgery protection to false on subscriptions controller spec
Diffstat (limited to 'spec')
-rw-r--r--spec/controllers/spree/admin/subscriptions_controller_spec.rb9
1 files changed, 9 insertions, 0 deletions
diff --git a/spec/controllers/spree/admin/subscriptions_controller_spec.rb b/spec/controllers/spree/admin/subscriptions_controller_spec.rb
index 3d8f256..310430f 100644
--- a/spec/controllers/spree/admin/subscriptions_controller_spec.rb
+++ b/spec/controllers/spree/admin/subscriptions_controller_spec.rb
@@ -1,8 +1,17 @@
require 'rails_helper'
+
RSpec.describe Spree::Admin::SubscriptionsController, type: :request do
extend Spree::TestingSupport::AuthorizationHelpers::Request
stub_authorization!
+ before do
+ ActionController::Base.allow_forgery_protection = false
+ end
+
+ after do
+ ActionController::Base.allow_forgery_protection = true
+ end
+
describe 'get /admin/subscriptions' do
subject do
get spree.admin_subscriptions_path