diff options
author | Filipa Lacerda <filipa@gitlab.com> | 2019-06-06 09:29:05 +0000 |
---|---|---|
committer | Filipa Lacerda <filipa@gitlab.com> | 2019-06-06 09:29:05 +0000 |
commit | 7468ed5fd28d08907384787d657d2bbe9af77411 (patch) | |
tree | 0b0c47859a84809f64d0d3bc8e8dd585662b0333 | |
parent | 5c3cab3d0fa5d5b3364523c974322a8a6552d48c (diff) | |
parent | 8af83bbfec20bb387436bbc46f6cfdac6aa05b71 (diff) | |
download | gitlab-ce-7468ed5fd28d08907384787d657d2bbe9af77411.tar.gz |
Merge branch 'always-show-pipelines-must-succeed-checkbox' into 'master'
Always show "Pipelines must succeed" checkbox
Closes #57291
See merge request gitlab-org/gitlab-ce!28651
4 files changed, 7 insertions, 7 deletions
diff --git a/app/assets/javascripts/pages/projects/shared/permissions/components/settings_panel.vue b/app/assets/javascripts/pages/projects/shared/permissions/components/settings_panel.vue index 19d9903c988..dea7c586868 100644 --- a/app/assets/javascripts/pages/projects/shared/permissions/components/settings_panel.vue +++ b/app/assets/javascripts/pages/projects/shared/permissions/components/settings_panel.vue @@ -175,11 +175,6 @@ export default { if (value === 0) toggleHiddenClassBySelector('.merge-requests-feature', true); else if (oldValue === 0) toggleHiddenClassBySelector('.merge-requests-feature', false); }, - - buildsAccessLevel(value, oldValue) { - if (value === 0) toggleHiddenClassBySelector('.builds-feature', true); - else if (oldValue === 0) toggleHiddenClassBySelector('.builds-feature', false); - }, }, methods: { diff --git a/app/views/projects/_merge_request_merge_checks_settings.html.haml b/app/views/projects/_merge_request_merge_checks_settings.html.haml index 1ab467a3710..c21d333f21a 100644 --- a/app/views/projects/_merge_request_merge_checks_settings.html.haml +++ b/app/views/projects/_merge_request_merge_checks_settings.html.haml @@ -3,7 +3,7 @@ .form-group %b= s_('ProjectSettings|Merge checks') %p.text-secondary= s_('ProjectSettings|These checks must pass before merge requests can be merged') - .form-check.mb-2.builds-feature{ class: ("hidden" if @project && @project.project_feature.send(:builds_access_level) == 0) } + .form-check.mb-2.builds-feature = form.check_box :only_allow_merge_if_pipeline_succeeds, class: 'form-check-input' = form.label :only_allow_merge_if_pipeline_succeeds, class: 'form-check-label' do = s_('ProjectSettings|Pipelines must succeed') diff --git a/changelogs/unreleased/always-show-pipelines-must-succeed-checkbox.yml b/changelogs/unreleased/always-show-pipelines-must-succeed-checkbox.yml new file mode 100644 index 00000000000..d60dd65be8a --- /dev/null +++ b/changelogs/unreleased/always-show-pipelines-must-succeed-checkbox.yml @@ -0,0 +1,5 @@ +--- +title: Always show "Pipelines must succeed" checkbox +merge_request: 28651 +author: +type: fixed diff --git a/spec/features/projects/settings/user_manages_merge_requests_settings_spec.rb b/spec/features/projects/settings/user_manages_merge_requests_settings_spec.rb index 28d52f25f56..0739726f52c 100644 --- a/spec/features/projects/settings/user_manages_merge_requests_settings_spec.rb +++ b/spec/features/projects/settings/user_manages_merge_requests_settings_spec.rb @@ -51,7 +51,7 @@ describe 'Projects > Settings > User manages merge request settings' do end it 'shows the Merge Requests settings that do not depend on Builds feature' do - expect(page).not_to have_content 'Pipelines must succeed' + expect(page).to have_content 'Pipelines must succeed' expect(page).to have_content 'All discussions must be resolved' within('.sharing-permissions-form') do |