diff options
author | Z.J. van de Weg <zegerjan@gitlab.com> | 2016-06-27 20:10:42 +0200 |
---|---|---|
committer | Z.J. van de Weg <zegerjan@gitlab.com> | 2016-06-27 20:10:42 +0200 |
commit | abca19da8b0ec12548140f8e771cfc08968d6972 (patch) | |
tree | 1db15dba43c2f51a423b8f71a1dbb87e5ea332e2 /spec/controllers/projects/project_members_controller_spec.rb | |
parent | e0e325625eb141445720999d4e4a4d60a4b59d95 (diff) | |
download | gitlab-ce-abca19da8b0ec12548140f8e771cfc08968d6972.tar.gz |
Use HTTP matchers if possible
Diffstat (limited to 'spec/controllers/projects/project_members_controller_spec.rb')
-rw-r--r-- | spec/controllers/projects/project_members_controller_spec.rb | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/spec/controllers/projects/project_members_controller_spec.rb b/spec/controllers/projects/project_members_controller_spec.rb index e5e750c855f..29aaceb2302 100644 --- a/spec/controllers/projects/project_members_controller_spec.rb +++ b/spec/controllers/projects/project_members_controller_spec.rb @@ -58,7 +58,7 @@ describe Projects::ProjectMembersController do get :index, namespace_id: project.namespace, project_id: project end - it { expect(response.status).to eq(200) } + it { expect(response).to have_http_status(200) } end end @@ -71,7 +71,7 @@ describe Projects::ProjectMembersController do project_id: project, id: 42 - expect(response.status).to eq(404) + expect(response).to have_http_status(404) end end @@ -94,7 +94,7 @@ describe Projects::ProjectMembersController do project_id: project, id: member - expect(response.status).to eq(404) + expect(response).to have_http_status(404) expect(project.users).to include team_user end end @@ -139,7 +139,7 @@ describe Projects::ProjectMembersController do delete :leave, namespace_id: project.namespace, project_id: project - expect(response.status).to eq(403) + expect(response).to have_http_status(403) end end @@ -171,7 +171,7 @@ describe Projects::ProjectMembersController do delete :leave, namespace_id: project.namespace, project_id: project - expect(response.status).to eq(403) + expect(response).to have_http_status(403) end end @@ -224,7 +224,7 @@ describe Projects::ProjectMembersController do project_id: project, id: 42 - expect(response.status).to eq(404) + expect(response).to have_http_status(404) end end @@ -247,7 +247,7 @@ describe Projects::ProjectMembersController do project_id: project, id: member - expect(response.status).to eq(404) + expect(response).to have_http_status(404) expect(project.users).not_to include team_requester end end |