Skip to content
Snippets Groups Projects
Commit 8818a2df authored by dakkar's avatar dakkar
Browse files

test that I've not broken whitespace handling

parent 4ff4ee6f
No related branches found
No related tags found
1 merge request!1push develop into stable
......@@ -815,6 +815,17 @@ hoge`;
assert.deepStrictEqual(mfm.parse(input), output);
});
test('newlines and whitespace', () => {
const input = 'before #abc\nafter #def\u3000foo #ghi\tbar #jkl';
const output = [
TEXT('before '), HASHTAG('abc'),
TEXT('\nafter '), HASHTAG('def'),
TEXT('\u3000foo '), HASHTAG('ghi'),
TEXT('\tbar '), HASHTAG('jkl'),
];
assert.deepStrictEqual(mfm.parse(input), output);
});
test('with keycap number sign', () => {
const input = '#️⃣abc123 #abc';
const output = [UNI_EMOJI('#️⃣'), TEXT('abc123 '), HASHTAG('abc')];
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment