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/lib/gitlab/static_site_editor/config_spec.rb | |
parent | 1ce776de4ae122aba3f349c02c17cebeaa8ecf07 (diff) |
Add latest changes from gitlab-org/gitlab@13-3-stable-ee
Diffstat (limited to 'spec/lib/gitlab/static_site_editor/config_spec.rb')
-rw-r--r-- | spec/lib/gitlab/static_site_editor/config_spec.rb | 22 |
1 files changed, 19 insertions, 3 deletions
diff --git a/spec/lib/gitlab/static_site_editor/config_spec.rb b/spec/lib/gitlab/static_site_editor/config_spec.rb index b60a6a9b006..56cdb573785 100644 --- a/spec/lib/gitlab/static_site_editor/config_spec.rb +++ b/spec/lib/gitlab/static_site_editor/config_spec.rb @@ -46,8 +46,6 @@ RSpec.describe Gitlab::StaticSiteEditor::Config do end context 'when file has .md.erb extension' do - let(:file_path) { 'README.md.erb' } - before do repository.create_file( project.creator, @@ -58,7 +56,25 @@ RSpec.describe Gitlab::StaticSiteEditor::Config do ) end - it { is_expected.to include(is_supported_content: 'true') } + context 'when feature flag is enabled' do + let(:file_path) { 'FEATURE_ON.md.erb' } + + before do + stub_feature_flags(sse_erb_support: project) + end + + it { is_expected.to include(is_supported_content: 'true') } + end + + context 'when feature flag is disabled' do + let(:file_path) { 'FEATURE_OFF.md.erb' } + + before do + stub_feature_flags(sse_erb_support: false) + end + + it { is_expected.to include(is_supported_content: 'false') } + end end context 'when file path is nested' do |