diff options
Diffstat (limited to 'spec/frontend/pages/shared')
-rw-r--r-- | spec/frontend/pages/shared/wikis/components/wiki_form_spec.js | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/spec/frontend/pages/shared/wikis/components/wiki_form_spec.js b/spec/frontend/pages/shared/wikis/components/wiki_form_spec.js index 1f964e8bae2..e118a35804f 100644 --- a/spec/frontend/pages/shared/wikis/components/wiki_form_spec.js +++ b/spec/frontend/pages/shared/wikis/components/wiki_form_spec.js @@ -155,6 +155,20 @@ describe('WikiForm', () => { }); it.each` + format | enabled | action + ${'markdown'} | ${true} | ${'displays'} + ${'rdoc'} | ${false} | ${'hides'} + ${'asciidoc'} | ${false} | ${'hides'} + ${'org'} | ${false} | ${'hides'} + `('$action preview in the markdown field when format is $format', async ({ format, enabled }) => { + createWrapper(); + + await setFormat(format); + + expect(findClassicEditor().props('enablePreview')).toBe(enabled); + }); + + it.each` value | text ${'markdown'} | ${'[Link Title](page-slug)'} ${'rdoc'} | ${'{Link title}[link:page-slug]'} |