From 0a11ea864237c3beea47011e2d1dbfa1b872eb76 Mon Sep 17 00:00:00 2001 From: Ryan Deba Date: Wed, 7 Mar 2018 20:23:12 -0600 Subject: [PATCH] add failing unit test --- test/specs/dom_components/model/Component.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/test/specs/dom_components/model/Component.js b/test/specs/dom_components/model/Component.js index ccc051a260..86ca5b5d69 100644 --- a/test/specs/dom_components/model/Component.js +++ b/test/specs/dom_components/model/Component.js @@ -135,6 +135,14 @@ module.exports = { expect(obj.toHTML()).toEqual('
'); }); + it('Component toHTML with quotes in attribute', () => { + obj = new Component(); + let attr = obj.get('attributes'); + attr['data-foo'] = '"bar"'; + obj.set('attributes', attr); + expect(obj.toHTML()).toEqual('
'); + }); + it('Component parse empty div', () => { var el = document.createElement('div'); obj = Component.isComponent(el);