gitlab-org--gitlab-foss/spec/support/forgery_protection.rb
2017-07-27 10:32:44 +02:00

11 lines
273 B
Ruby

RSpec.configure do |config|
config.around(:each, :allow_forgery_protection) do |example|
begin
ActionController::Base.allow_forgery_protection = true
example.call
ensure
ActionController::Base.allow_forgery_protection = false
end
end
end