Skip to content

Commit e7eb26f

Browse files
committed
Test handling of more non-standard markup
Fixes jsdom#88.
1 parent b7d69c5 commit e7eb26f

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

test/jsdom/parsing.js

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -206,3 +206,18 @@ exports["Handle missing <body> tag correctly (GH-389)"] = function (t) {
206206
}
207207
});
208208
};
209+
210+
exports["Handle more non-standard markup (GH-88)"] = function (t) {
211+
var doc;
212+
213+
doc = jsdom("<html><body></body></html>");
214+
t.strictEqual(doc.body.innerHTML, "");
215+
216+
doc = jsdom("<body></body>");
217+
t.strictEqual(doc.body.innerHTML, "");
218+
219+
doc = jsdom("gavin!");
220+
t.strictEqual(doc.body.innerHTML, "gavin!");
221+
222+
t.done();
223+
};

0 commit comments

Comments
 (0)