Commit 266bb560 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets Committed by Natalia Tepluhina

Show warning when autodevops is enabled without registry

Signed-off-by: default avatarDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
parent 69d55850
......@@ -7,3 +7,7 @@
= link_to _('Settings'), project_settings_ci_cd_path(project), class: 'alert-link'
|
= link_to _('Dismiss'), '#', class: 'hide-auto-devops-implicitly-enabled-banner alert-link', data: { project_id: project.id }
- unless Gitlab.config.registry.enabled
%div
= icon('exclamation-triangle')
= _('Container registry is not enabled on this GitLab instance. Ask an administrator to enable it in order for AutoDevOps to work.')
---
title: Add extra sentence about registry to AutoDevOps popup
merge_request: 19092
author:
type: changed
......@@ -4391,6 +4391,9 @@ msgstr ""
msgid "Container registry images"
msgstr ""
msgid "Container registry is not enabled on this GitLab instance. Ask an administrator to enable it in order for AutoDevOps to work."
msgstr ""
msgid "ContainerRegistry|Container Registry"
msgstr ""
......
......@@ -57,5 +57,18 @@ describe 'Project > Show > User interacts with auto devops implicitly enabled ba
expect(page).not_to have_css('.auto-devops-implicitly-enabled-banner')
end
end
context 'when AutoDevOps enabled but container registry is disabled' do
before do
stub_application_setting(auto_devops_enabled: true)
stub_container_registry_config(enabled: false)
visit project_path(project)
end
it 'shows message that container registry is disabled' do
expect(page).to have_content('Container registry is not enabled on this GitLab instance')
end
end
end
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment