Skip to content

Commit b7d69c5

Browse files
committed
Test handling of missing <body> tag
Fixes jsdom#389.
1 parent 12cae8c commit b7d69c5

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

test/jsdom/parsing.js

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -192,3 +192,17 @@ exports["Handle missing <html> tag correctly (GH-555)"] = function (t) {
192192

193193
t.done();
194194
};
195+
196+
exports["Handle missing <body> tag correctly (GH-389)"] = function (t) {
197+
t.expect(1);
198+
199+
jsdom.env({
200+
html: "<html></html>",
201+
src: "''",
202+
done: function (errs, window) {
203+
t.ifError(errs);
204+
205+
t.done();
206+
}
207+
});
208+
};

0 commit comments

Comments
 (0)