diff options
Diffstat (limited to 'src/tests/markdown.spec.js')
-rw-r--r-- | src/tests/markdown.spec.js | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/tests/markdown.spec.js b/src/tests/markdown.spec.js index f71dde3b0..7f84cd4a6 100644 --- a/src/tests/markdown.spec.js +++ b/src/tests/markdown.spec.js @@ -152,6 +152,10 @@ describe('Markdown though editor', () => { expect(markdownThroughEditor(entry)).toBe(entry) }) }) + + test('mentions', () => { + expect(markdownThroughEditor('@[username](mention://user/id)')).toBe(' @[username](mention://user/id) ') + }) }) describe('Markdown serializer from html', () => { @@ -203,6 +207,10 @@ describe('Markdown serializer from html', () => { // Test --- within front matter is allowed expect(markdownThroughEditorHtml('<pre id="frontmatter"><code>---</code></pre><h1>Heading</h1>')).toBe('----\n---\n----\n\n# Heading') }) + + test('mentions', () => { + expect(markdownThroughEditorHtml('<span class="mention" data-label="username" data-type="user" data-id="id">username</span>')).toBe(' @[username](mention://user/id) ') + }) }) describe('Trailing nodes', () => { |