mirror of
https://activitypub.software/TransFem-org/sfm-js
synced 2024-11-22 05:55:13 +00:00
add test
This commit is contained in:
parent
6ac576b748
commit
2030fd3537
1 changed files with 6 additions and 0 deletions
|
@ -426,6 +426,12 @@ describe('FullParser', () => {
|
|||
|
||||
describe('hashtag', () => {
|
||||
it('basic', () => {
|
||||
const input = '#abc';
|
||||
const output = [HASHTAG('abc')];
|
||||
assert.deepStrictEqual(mfm.parse(input), output);
|
||||
});
|
||||
|
||||
it('basic 2', () => {
|
||||
const input = 'before #abc after';
|
||||
const output = [TEXT('before '), HASHTAG('abc'), TEXT(' after')];
|
||||
assert.deepStrictEqual(mfm.parse(input), output);
|
||||
|
|
Loading…
Reference in a new issue