Commit 7fdf979e authored by Jasper Maes's avatar Jasper Maes

Rails5 fix ArgumentError: wrong number of arguments (given 1, expected 2)

parent 14a11461
---
title: 'Rails5 fix ArgumentError: wrong number of arguments (given 1, expected 2)'
merge_request: 6272
author: Jasper Maes
type: fixed
......@@ -3,8 +3,13 @@ require 'spec_helper'
describe ::Applications::CreateService do
let(:user) { create(:user) }
let(:params) { attributes_for(:application) }
let(:request) { ActionController::TestRequest.new(remote_ip: '127.0.0.1') }
let(:request) do
if Gitlab.rails5?
ActionController::TestRequest.new({ remote_ip: "127.0.0.1" }, ActionController::TestSession.new)
else
ActionController::TestRequest.new(remote_ip: "127.0.0.1")
end
end
subject { described_class.new(user, params) }
it 'creates an audit log' do
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment