diff options
Diffstat (limited to 'spec/requests/health_controller_spec.rb')
-rw-r--r-- | spec/requests/health_controller_spec.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/spec/requests/health_controller_spec.rb b/spec/requests/health_controller_spec.rb index 61412815039..6ee716e0e89 100644 --- a/spec/requests/health_controller_spec.rb +++ b/spec/requests/health_controller_spec.rb @@ -37,7 +37,7 @@ describe HealthController do it 'responds with resource not found' do subject - expect(response.status).to eq(404) + expect(response).to have_gitlab_http_status(:not_found) end end @@ -48,7 +48,7 @@ describe HealthController do it 'responds with health checks data' do subject - expect(response.status).to eq(200) + expect(response).to have_gitlab_http_status(:ok) expect(response.body).to eq('GitLab OK') end end @@ -95,7 +95,7 @@ describe HealthController do expect(json_response['master_check']).to contain_exactly( { 'status' => 'failed', 'message' => 'unexpected Master check result: false' }) - expect(response.status).to eq(503) + expect(response).to have_gitlab_http_status(:service_unavailable) expect(response.headers['X-GitLab-Custom-Error']).to eq(1) end end @@ -126,7 +126,7 @@ describe HealthController do expect(json_response['redis_check']).to contain_exactly( { 'status' => 'failed', 'message' => 'check error' }) - expect(response.status).to eq(503) + expect(response).to have_gitlab_http_status(:service_unavailable) expect(response.headers['X-GitLab-Custom-Error']).to eq(1) end end |