[MFM] Better hashtag parsing: Ignore single quotation

This commit is contained in:
syuilo
2019-01-17 09:33:08 +09:00
parent 9740db8685
commit cb6a4037f2
2 changed files with 9 additions and 1 deletions

View File

@ -365,6 +365,14 @@ describe('MFM', () => {
]);
});
it('ignore single quote', () => {
const tokens = analyze('#foo\'');
assert.deepStrictEqual(tokens, [
leaf('hashtag', { hashtag: 'foo' }),
text('\''),
]);
});
it('ignore double quote', () => {
const tokens = analyze('#foo"');
assert.deepStrictEqual(tokens, [