aboutsummaryrefslogtreecommitdiff
path: root/test/unit
diff options
context:
space:
mode:
Diffstat (limited to 'test/unit')
-rw-r--r--test/unit/specs/components/rich_content.spec.js23
1 files changed, 23 insertions, 0 deletions
diff --git a/test/unit/specs/components/rich_content.spec.js b/test/unit/specs/components/rich_content.spec.js
index 96c480ea..fbf8973d 100644
--- a/test/unit/specs/components/rich_content.spec.js
+++ b/test/unit/specs/components/rich_content.spec.js
@@ -27,6 +27,29 @@ describe('RichContent', () => {
expect(wrapper.html()).to.eql(compwrap(html))
})
+ it('unescapes everything as needed', () => {
+ const html = [
+ p('Testing 'em all'),
+ 'Testing 'em all'
+ ].join('')
+ const expected = [
+ p('Testing \'em all'),
+ 'Testing \'em all'
+ ].join('')
+ const wrapper = shallowMount(RichContent, {
+ localVue,
+ propsData: {
+ hideMentions: true,
+ handleLinks: true,
+ greentext: true,
+ emoji: [],
+ html
+ }
+ })
+
+ expect(wrapper.html()).to.eql(compwrap(expected))
+ })
+
it('removes mentions from the beginning of post', () => {
const html = p(
makeMention('John'),