diff --git a/app/models/project_feature.rb b/app/models/project_feature.rb index c8287628716af77e81838c24db698f45cfadb79a..fa19ffe86da258e86f85b481248f9f3d46bdac5b 100644 --- a/app/models/project_feature.rb +++ b/app/models/project_feature.rb @@ -30,7 +30,7 @@ class ProjectFeature < ApplicationRecord model_registry ].freeze - EXPORTABLE_FEATURES = (FEATURES - [:security_and_compliance, :pages]).freeze + EXPORTABLE_FEATURES = (FEATURES - [:security_and_compliance, :pages, :metrics_dashboard]).freeze set_available_features(FEATURES) diff --git a/ee/spec/models/ee/user_spec.rb b/ee/spec/models/ee/user_spec.rb index 1fcedc47814cda3ae54e9c4758dc09768a31a779..a469e6563476ba00ea396792319ca675a3ecd829 100644 --- a/ee/spec/models/ee/user_spec.rb +++ b/ee/spec/models/ee/user_spec.rb @@ -798,6 +798,10 @@ expect(user.available_custom_project_templates).to include public_project end + it 'returns internal projects' do + expect(user.available_custom_project_templates).to include internal_project + end + context 'returns private projects if user' do it 'is a member of the project' do expect(user.available_custom_project_templates).not_to include private_project @@ -816,24 +820,6 @@ end end - context 'returns internal projects if user' do - it 'is a member of the project' do - expect(user.available_custom_project_templates).not_to include internal_project - - internal_project.add_developer(user) - - expect(user.available_custom_project_templates).to include internal_project - end - - it 'is a member of the group' do - expect(user.available_custom_project_templates).not_to include internal_project - - group.add_developer(user) - - expect(user.available_custom_project_templates).to include internal_project - end - end - it 'allows to search available project templates by name' do projects = user.available_custom_project_templates(search: 'publi')