Enable group wikis import/export

In this commit we enable the functionality of group wikis
import/export for premium users.
parent a3a4846b
---
name: group_wiki_import_export
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/51873
rollout_issue_url:
milestone: '13.9'
type: development
group: group::editor
default_enabled: false
......@@ -6,7 +6,7 @@ module EE
override :group_export_descriptions
def group_export_descriptions
super + [_('Epics'), _('Events')]
super + [_('Epics'), _('Events'), _('Group Wikis')]
end
end
end
......@@ -9,7 +9,6 @@ module EE
override :savers
def savers
return super unless ndjson?
return super if ::Feature.disabled?(:group_wiki_import_export, group)
super << group_and_descendants_repo_saver
end
......
......@@ -9,7 +9,6 @@ module EE
override :restorers
def restorers
return super unless ndjson?
return super if ::Feature.disabled?(:group_wiki_import_export, group)
super << group_and_descendants_repo_restorer
end
......
---
title: Add group wikis import/export functionality
merge_request: 53247
author:
type: added
# frozen_string_literal: true
require 'spec_helper'
RSpec.describe ExportHelper do
describe '#group_export_descriptions' do
it 'includes EE features in the description' do
expect(helper.group_export_descriptions).to include('Epics', 'Events', 'Group Wikis')
end
end
end
......@@ -47,16 +47,6 @@ RSpec.describe Groups::ImportExport::ExportService do
expect(File.exist?(Gitlab::ImportExport.group_wiki_repo_bundle_full_path(shared, subgroup.id))).to eq true
end
context 'when feature flag :group_wiki_import_export is disabled' do
it 'does not export group wiki repositories' do
stub_feature_flags(group_wiki_import_export: false)
expect(::Gitlab::ImportExport::Group::GroupAndDescendantsRepoSaver).not_to receive(:new)
export_service.execute
end
end
context 'when ndjson is not enabled' do
it 'does not export group wiki repositories' do
allow(export_service).to receive(:ndjson?).and_return(false)
......
......@@ -41,16 +41,6 @@ RSpec.describe Groups::ImportExport::ImportService do
end
end
context 'when feature flag :group_wiki_import_export is disabled' do
it 'does not export group wiki repositories' do
stub_feature_flags(group_wiki_import_export: false)
expect(::Gitlab::ImportExport::Group::GroupAndDescendantsRepoRestorer).not_to receive(:new)
import_service.execute
end
end
context 'when export file not in ndjson format' do
let(:import_file) { fixture_file_upload('spec/fixtures/legacy_group_export.tar.gz') }
......
......@@ -14044,6 +14044,9 @@ msgstr ""
msgid "Group URL"
msgstr ""
msgid "Group Wikis"
msgstr ""
msgid "Group avatar"
msgstr ""
......
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