diff options
| author | Henry Jameson <me@hjkos.com> | 2021-06-12 21:49:40 +0300 |
|---|---|---|
| committer | Henry Jameson <me@hjkos.com> | 2021-06-12 21:49:56 +0300 |
| commit | 9c70f3e4df2e28863b51156fdbd25e253a3a1b98 (patch) | |
| tree | 4ee91fd50829fe4853d2e2af395163995d4a0709 /test | |
| parent | 2c60a9b638a00db33e6c47e8642aff2ffd0ce7a0 (diff) | |
fixed a bug + made a testcase out of it
Diffstat (limited to 'test')
| -rw-r--r-- | test/unit/specs/components/rich_content.spec.js | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/test/unit/specs/components/rich_content.spec.js b/test/unit/specs/components/rich_content.spec.js index 20322019..ff491a3a 100644 --- a/test/unit/specs/components/rich_content.spec.js +++ b/test/unit/specs/components/rich_content.spec.js @@ -381,4 +381,39 @@ describe('RichContent', () => { expect(wrapper.html()).to.eql(compwrap(expected)) }) + + it('One buggy example', () => { + const html = [ + 'Bruh', + 'Bruh', + [ + makeMention('foo'), + makeMention('bar'), + makeMention('baz') + ].join(''), + 'Bruh' + ].join('<br>') + const expected = [ + 'Bruh', + 'Bruh', + [ + stubMention('foo'), + stubMention('bar'), + stubMention('baz') + ].join(''), + 'Bruh' + ].join('<br>') + + const wrapper = shallowMount(RichContent, { + localVue, + propsData: { + handleLinks: true, + greentext: true, + emoji: [], + html + } + }) + + expect(wrapper.html()).to.eql(compwrap(expected)) + }) }) |
