|
|
|
@ -135,6 +135,16 @@ module.exports = { |
|
|
|
expect(obj.toHTML()).toEqual('<div/>'); |
|
|
|
}); |
|
|
|
|
|
|
|
it('Component toHTML with quotes in attribute', () => { |
|
|
|
obj = new Component(); |
|
|
|
let attrs = obj.get('attributes'); |
|
|
|
attrs['data-test'] = '"value"'; |
|
|
|
obj.set('attributes', attrs); |
|
|
|
expect(obj.toHTML()).toEqual( |
|
|
|
'<div data-test=""value""></div>' |
|
|
|
); |
|
|
|
}); |
|
|
|
|
|
|
|
it('Component parse empty div', () => { |
|
|
|
var el = document.createElement('div'); |
|
|
|
obj = Component.isComponent(el); |
|
|
|
|