Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2023-04-20 15:21:30 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2023-04-20 15:21:30 +0300
commit2366f969a4b3a95e052e551cc7283a2db8d5562e (patch)
tree33ea679dad4b92048697729f68f9c606f91b32e4 /spec/frontend/content_editor
parentc7eec01f1b68b2e047cdd709751cb695ab329933 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/frontend/content_editor')
-rw-r--r--spec/frontend/content_editor/services/markdown_serializer_spec.js13
1 files changed, 13 insertions, 0 deletions
diff --git a/spec/frontend/content_editor/services/markdown_serializer_spec.js b/spec/frontend/content_editor/services/markdown_serializer_spec.js
index a28d5a278e6..506db4144fc 100644
--- a/spec/frontend/content_editor/services/markdown_serializer_spec.js
+++ b/spec/frontend/content_editor/services/markdown_serializer_spec.js
@@ -186,6 +186,19 @@ comment -->
);
});
+ it('correctly renders a comment with markdown in it without adding any slashes', () => {
+ expect(serialize(paragraph('hi'), comment('this is a list\n- a\n- b\n- c'))).toBe(
+ `
+hi
+
+<!--this is a list
+- a
+- b
+- c-->
+ `.trim(),
+ );
+ });
+
it('correctly serializes a line break', () => {
expect(serialize(paragraph('hello', hardBreak(), 'world'))).toBe('hello\\\nworld');
});