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:
authorDouwe Maan <douwe@selenight.nl>2019-01-23 14:21:12 +0300
committerDouwe Maan <douwe@selenight.nl>2019-01-24 14:06:53 +0300
commit8a03dbf8b7e6776264cef9824aba1e58dcbaef70 (patch)
tree07612ef69e0c6404bcbf382225e23b67ca5c2cff /spec/javascripts/behaviors
parenta7e77e10fec4c37782edf09aafa12ae0c2d870df (diff)
Use nodes and marks to power Copy-as-GFM
The spec needed to be updated because in some cases the resulting Markdown is slightly different, though equally valid.
Diffstat (limited to 'spec/javascripts/behaviors')
-rw-r--r--spec/javascripts/behaviors/copy_as_gfm_spec.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/javascripts/behaviors/copy_as_gfm_spec.js b/spec/javascripts/behaviors/copy_as_gfm_spec.js
index cf8c1b77861..6179a02ce16 100644
--- a/spec/javascripts/behaviors/copy_as_gfm_spec.js
+++ b/spec/javascripts/behaviors/copy_as_gfm_spec.js
@@ -87,7 +87,7 @@ describe('CopyAsGFM', () => {
spyOn(window, 'getSelection').and.returnValue(selection);
simulateCopy();
- const expectedGFM = '- List Item1\n- List Item2';
+ const expectedGFM = '* List Item1\n\n* List Item2';
expect(clipboardData.setData).toHaveBeenCalledWith('text/x-gfm', expectedGFM);
});
@@ -97,7 +97,7 @@ describe('CopyAsGFM', () => {
spyOn(window, 'getSelection').and.returnValue(selection);
simulateCopy();
- const expectedGFM = '1. List Item1\n1. List Item2';
+ const expectedGFM = '1. List Item1\n\n1. List Item2';
expect(clipboardData.setData).toHaveBeenCalledWith('text/x-gfm', expectedGFM);
});