- describe('Internal HTML representation of a sample document', function() {
- it('works', function() {
- var c = canvas.fromXML('\
- <section>\
- This is some text without its own wrapping tag.\
- <div class="p.subclass">\
- This is a paragraph.\
- </div>\
- <div>\
- This is text in a div <span>with some inline text</span>.\
- </div>\
- This is some text without its own wrapping tag.\
- </section>\
- ');
- var expected = '<div wlxml-tag="section">'
- + '<div wlxml-text>This is some text without its own wrapping tag.</div>'
- + '<div wlxml-tag="div" wlxml-class="p-subclass">'
- + '<div wlxml-text>This is a paragraph.</div>'
- + '</div>'
- + '<div wlxml-tag="div">'
- + '<div wlxml-text>This is text in a div </div>'
- + '<div wlxml-tag="span">'
- + '<div wlxml-text>with some inline text</div>'
- + '</div>'
- + '<div wlxml-text>.</div>'
- + '</div>'
- + '<div wlxml-text>This is some text without its own wrapping tag.</div>'
- + '</div>';
- expect(c.doc().dom()[0].isEqualNode($(expected)[0])).to.be.true;
- });
- });
-