diff options
author | Grzegorz Bizon <grzegorz@gitlab.com> | 2019-02-05 16:23:28 +0300 |
---|---|---|
committer | Grzegorz Bizon <grzegorz@gitlab.com> | 2019-02-05 16:23:28 +0300 |
commit | fedecbbe01f56897620ba56182c57e592e2cd6ac (patch) | |
tree | bb86c40197170113216a253d88f0228afb65701d /spec/helpers | |
parent | fb296ab57128f2da25e69cd8453fed86bf44748d (diff) | |
parent | b2c70230b35e72826f55acfd6b44bfabd19302bb (diff) |
Merge branch 'jprovazn-remove-redcarpet' into 'master'
Remove Redcarpet markdown engine
Closes #51374
See merge request gitlab-org/gitlab-ce!24819
Diffstat (limited to 'spec/helpers')
-rw-r--r-- | spec/helpers/issuables_helper_spec.rb | 1 | ||||
-rw-r--r-- | spec/helpers/markup_helper_spec.rb | 21 | ||||
-rw-r--r-- | spec/helpers/projects_helper_spec.rb | 12 |
3 files changed, 0 insertions, 34 deletions
diff --git a/spec/helpers/issuables_helper_spec.rb b/spec/helpers/issuables_helper_spec.rb index af319e5ebfe..8b82dea2524 100644 --- a/spec/helpers/issuables_helper_spec.rb +++ b/spec/helpers/issuables_helper_spec.rb @@ -188,7 +188,6 @@ describe IssuablesHelper do issuableRef: "##{issue.iid}", markdownPreviewPath: "/#{@project.full_path}/preview_markdown", markdownDocsPath: '/help/user/markdown', - markdownVersion: CacheMarkdownField::CACHE_COMMONMARK_VERSION, issuableTemplates: [], lockVersion: issue.lock_version, projectPath: @project.path, diff --git a/spec/helpers/markup_helper_spec.rb b/spec/helpers/markup_helper_spec.rb index a0c0af94fa5..c3956ba08fd 100644 --- a/spec/helpers/markup_helper_spec.rb +++ b/spec/helpers/markup_helper_spec.rb @@ -212,17 +212,6 @@ describe MarkupHelper do helper.render_wiki_content(@wiki) end - it 'uses Wiki pipeline for markdown files with RedCarpet if feature disabled' do - stub_feature_flags(commonmark_for_repositories: false) - allow(@wiki).to receive(:format).and_return(:markdown) - - expect(helper).to receive(:markdown_unsafe).with('wiki content', - pipeline: :wiki, project: project, project_wiki: @wiki, page_slug: "nested/page", - issuable_state_filter_enabled: true, markdown_engine: :redcarpet) - - helper.render_wiki_content(@wiki) - end - it "uses Asciidoctor for asciidoc files" do allow(@wiki).to receive(:format).and_return(:asciidoc) @@ -273,16 +262,6 @@ describe MarkupHelper do it 'defaults to CommonMark' do expect(helper.markup('foo.md', 'x^2')).to include('x^2') end - - it 'honors markdown_engine for RedCarpet' do - expect(helper.markup('foo.md', 'x^2', { markdown_engine: :redcarpet })).to include('x<sup>2</sup>') - end - - it 'uses RedCarpet if feature disabled' do - stub_feature_flags(commonmark_for_repositories: false) - - expect(helper.markup('foo.md', 'x^2', { markdown_engine: :redcarpet })).to include('x<sup>2</sup>') - end end describe '#first_line_in_markdown' do diff --git a/spec/helpers/projects_helper_spec.rb b/spec/helpers/projects_helper_spec.rb index 990750f0b2f..49895b0680b 100644 --- a/spec/helpers/projects_helper_spec.rb +++ b/spec/helpers/projects_helper_spec.rb @@ -535,18 +535,6 @@ describe ProjectsHelper do end end - describe '#legacy_render_context' do - it 'returns the redcarpet engine' do - params = { legacy_render: '1' } - - expect(helper.legacy_render_context(params)).to include(markdown_engine: :redcarpet) - end - - it 'returns nothing' do - expect(helper.legacy_render_context({})).to be_empty - end - end - describe '#explore_projects_tab?' do subject { helper.explore_projects_tab? } |