From 2f40dac35280f9de9af8c47bdf85c2f0b2d53680 Mon Sep 17 00:00:00 2001 From: Jacopo Date: Thu, 19 Oct 2017 20:28:19 +0200 Subject: Refactor `have_http_status` into `have_gitlab_http_status` in the specs --- spec/requests/api/v3/system_hooks_spec.rb | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'spec/requests/api/v3/system_hooks_spec.rb') diff --git a/spec/requests/api/v3/system_hooks_spec.rb b/spec/requests/api/v3/system_hooks_spec.rb index ae427541abb..30711c60faa 100644 --- a/spec/requests/api/v3/system_hooks_spec.rb +++ b/spec/requests/api/v3/system_hooks_spec.rb @@ -12,7 +12,7 @@ describe API::V3::SystemHooks do it "returns authentication error" do get v3_api("/hooks") - expect(response).to have_http_status(401) + expect(response).to have_gitlab_http_status(401) end end @@ -20,7 +20,7 @@ describe API::V3::SystemHooks do it "returns forbidden error" do get v3_api("/hooks", user) - expect(response).to have_http_status(403) + expect(response).to have_gitlab_http_status(403) end end @@ -28,7 +28,7 @@ describe API::V3::SystemHooks do it "returns an array of hooks" do get v3_api("/hooks", admin) - expect(response).to have_http_status(200) + expect(response).to have_gitlab_http_status(200) expect(json_response).to be_an Array expect(json_response.first['url']).to eq(hook.url) expect(json_response.first['push_events']).to be false @@ -43,14 +43,14 @@ describe API::V3::SystemHooks do expect do delete v3_api("/hooks/#{hook.id}", admin) - expect(response).to have_http_status(200) + expect(response).to have_gitlab_http_status(200) end.to change { SystemHook.count }.by(-1) end it 'returns 404 if the system hook does not exist' do delete v3_api('/hooks/12345', admin) - expect(response).to have_http_status(404) + expect(response).to have_gitlab_http_status(404) end end end -- cgit v1.2.1