diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-08-20 21:42:06 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-08-20 21:42:06 +0300 |
commit | 6e4e1050d9dba2b7b2523fdd1768823ab85feef4 (patch) | |
tree | 78be5963ec075d80116a932011d695dd33910b4e /spec/controllers/projects/pipelines/tests_controller_spec.rb | |
parent | 1ce776de4ae122aba3f349c02c17cebeaa8ecf07 (diff) |
Add latest changes from gitlab-org/gitlab@13-3-stable-ee
Diffstat (limited to 'spec/controllers/projects/pipelines/tests_controller_spec.rb')
-rw-r--r-- | spec/controllers/projects/pipelines/tests_controller_spec.rb | 32 |
1 files changed, 2 insertions, 30 deletions
diff --git a/spec/controllers/projects/pipelines/tests_controller_spec.rb b/spec/controllers/projects/pipelines/tests_controller_spec.rb index e2abd1238c5..61118487e20 100644 --- a/spec/controllers/projects/pipelines/tests_controller_spec.rb +++ b/spec/controllers/projects/pipelines/tests_controller_spec.rb @@ -19,7 +19,7 @@ RSpec.describe Projects::Pipelines::TestsController do get_tests_summary_json expect(response).to have_gitlab_http_status(:ok) - expect(json_response['total_count']).to eq(2) + expect(json_response.dig('total', 'count')).to eq(2) end end @@ -28,20 +28,7 @@ RSpec.describe Projects::Pipelines::TestsController do get_tests_summary_json expect(response).to have_gitlab_http_status(:ok) - expect(json_response['total_count']).to eq(0) - end - end - - context 'when feature is disabled' do - before do - stub_feature_flags(build_report_summary: false) - end - - it 'returns 404' do - get_tests_summary_json - - expect(response).to have_gitlab_http_status(:not_found) - expect(response.body).to be_empty + expect(json_response.dig('total', 'count')).to eq(0) end end end @@ -71,21 +58,6 @@ RSpec.describe Projects::Pipelines::TestsController do expect(response.body).to be_empty end end - - context 'when feature is disabled' do - let(:suite_name) { 'test' } - - before do - stub_feature_flags(build_report_summary: false) - end - - it 'returns 404' do - get_tests_show_json([]) - - expect(response).to have_gitlab_http_status(:not_found) - expect(response.body).to be_empty - end - end end def get_tests_summary_json |