summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorLin Jen-Shin <godfat@godfat.org>2019-01-03 14:48:58 +0000
committerLin Jen-Shin <godfat@godfat.org>2019-01-03 14:48:58 +0000
commit54a14270a6363ff2344453e8d376f0a294de798a (patch)
treef9069dc5548709167a72c02a645ea446193ff58e /spec
parent420442c5036b08652a758179d893bf8fe2b798ef (diff)
parentd53755da68c660b2393a931e063e46e455adcec9 (diff)
downloadgitlab-ce-54a14270a6363ff2344453e8d376f0a294de798a.tar.gz
Merge branch 'deprecated-positional-spec-arguments' into 'master'
Fix deprecation: Using positional arguments in integration tests See merge request gitlab-org/gitlab-ce!24110
Diffstat (limited to 'spec')
-rw-r--r--spec/controllers/projects/merge_requests_controller_spec.rb8
-rw-r--r--spec/controllers/projects/snippets_controller_spec.rb2
-rw-r--r--spec/controllers/projects_controller_spec.rb2
-rw-r--r--spec/controllers/snippets_controller_spec.rb6
4 files changed, 9 insertions, 9 deletions
diff --git a/spec/controllers/projects/merge_requests_controller_spec.rb b/spec/controllers/projects/merge_requests_controller_spec.rb
index d46b9ffb3ce..4f4d3ca226f 100644
--- a/spec/controllers/projects/merge_requests_controller_spec.rb
+++ b/spec/controllers/projects/merge_requests_controller_spec.rb
@@ -950,7 +950,7 @@ describe Projects::MergeRequestsController do
end
it 'returns 200' do
- get :discussions, namespace_id: project.namespace, project_id: project, id: merge_request.iid
+ get :discussions, params: { namespace_id: project.namespace, project_id: project, id: merge_request.iid }
expect(response.status).to eq(200)
end
@@ -969,7 +969,7 @@ describe Projects::MergeRequestsController do
expect(collection).to receive(:find_by_id).with(note_diff_file.id).and_call_original
end
- get :discussions, namespace_id: project.namespace, project_id: project, id: merge_request.iid
+ get :discussions, params: { namespace_id: project.namespace, project_id: project, id: merge_request.iid }
end
end
@@ -986,7 +986,7 @@ describe Projects::MergeRequestsController do
expect(collection).to receive(:find_by_id).with(note_diff_file.id).and_call_original
end
- get :discussions, namespace_id: project.namespace, project_id: project, id: merge_request.iid
+ get :discussions, params: { namespace_id: project.namespace, project_id: project, id: merge_request.iid }
end
it 'does not preload highlights when diff note is resolved' do
@@ -999,7 +999,7 @@ describe Projects::MergeRequestsController do
expect(collection).to receive(:find_by_id).with(note_diff_file.id).and_call_original
end
- get :discussions, namespace_id: project.namespace, project_id: project, id: merge_request.iid
+ get :discussions, params: { namespace_id: project.namespace, project_id: project, id: merge_request.iid }
end
end
end
diff --git a/spec/controllers/projects/snippets_controller_spec.rb b/spec/controllers/projects/snippets_controller_spec.rb
index e4b78aff25d..75c9839dd9b 100644
--- a/spec/controllers/projects/snippets_controller_spec.rb
+++ b/spec/controllers/projects/snippets_controller_spec.rb
@@ -385,7 +385,7 @@ describe Projects::SnippetsController do
before do
sign_in(user)
- get :show, namespace_id: project.namespace, project_id: project, id: project_snippet.to_param, format: :js
+ get :show, params: { namespace_id: project.namespace, project_id: project, id: project_snippet.to_param }, format: :js
end
context 'when snippet is private' do
diff --git a/spec/controllers/projects_controller_spec.rb b/spec/controllers/projects_controller_spec.rb
index 4747d837273..f84f069f4db 100644
--- a/spec/controllers/projects_controller_spec.rb
+++ b/spec/controllers/projects_controller_spec.rb
@@ -667,7 +667,7 @@ describe ProjectsController do
project.add_guest(user)
sign_in(user)
- get :refs, namespace_id: project.namespace, id: project
+ get :refs, params: { namespace_id: project.namespace, id: project }
expect(response).to have_gitlab_http_status(404)
end
diff --git a/spec/controllers/snippets_controller_spec.rb b/spec/controllers/snippets_controller_spec.rb
index d762531da7e..5c6858dc7b2 100644
--- a/spec/controllers/snippets_controller_spec.rb
+++ b/spec/controllers/snippets_controller_spec.rb
@@ -82,7 +82,7 @@ describe SnippetsController do
end
it 'responds with status 404 when embeddable content is requested' do
- get :show, id: personal_snippet.to_param, format: :js
+ get :show, params: { id: personal_snippet.to_param }, format: :js
expect(response).to have_gitlab_http_status(404)
end
@@ -114,7 +114,7 @@ describe SnippetsController do
end
it 'responds with status 404 when embeddable content is requested' do
- get :show, id: personal_snippet.to_param, format: :js
+ get :show, params: { id: personal_snippet.to_param }, format: :js
expect(response).to have_gitlab_http_status(404)
end
@@ -145,7 +145,7 @@ describe SnippetsController do
end
it 'responds with status 200 when embeddable content is requested' do
- get :show, id: personal_snippet.to_param, format: :js
+ get :show, params: { id: personal_snippet.to_param }, format: :js
expect(assigns(:snippet)).to eq(personal_snippet)
expect(response).to have_gitlab_http_status(200)