diff --git a/Tests/LibWeb/Text/expected/wpt-import/dom/nodes/Comment-constructor.txt b/Tests/LibWeb/Text/expected/wpt-import/dom/nodes/Comment-constructor.txt new file mode 100644 index 00000000000..228990e03f5 --- /dev/null +++ b/Tests/LibWeb/Text/expected/wpt-import/dom/nodes/Comment-constructor.txt @@ -0,0 +1,26 @@ +Summary + +Harness status: OK + +Rerun + +Found 16 tests + +16 Pass +Details +Result Test Name MessagePass new Comment(): prototype chain +Pass new Comment(): instanceof +Pass new Comment(): no arguments +Pass new Comment(): undefined +Pass new Comment(): null +Pass new Comment(): 42 +Pass new Comment(): "" +Pass new Comment(): "-" +Pass new Comment(): "--" +Pass new Comment(): "-->" +Pass new Comment(): "" +Pass new Text(): "", "-->"], + [" +DOMImplementation.createHTMLDocument + + + + + + + + +
+ diff --git a/Tests/LibWeb/Text/input/wpt-import/dom/nodes/DOMImplementation-createHTMLDocument.js b/Tests/LibWeb/Text/input/wpt-import/dom/nodes/DOMImplementation-createHTMLDocument.js new file mode 100644 index 00000000000..3e7e9aa9b78 --- /dev/null +++ b/Tests/LibWeb/Text/input/wpt-import/dom/nodes/DOMImplementation-createHTMLDocument.js @@ -0,0 +1,25 @@ +function createHTMLDocuments(checkDoc) { + var tests = [ + ["", "", ""], + [null, "null", "null"], + [undefined, undefined, ""], + ["foo bar baz", "foo bar baz", "foo bar baz"], + ["foo\t\tbar baz", "foo\t\tbar baz", "foo bar baz"], + ["foo\n\nbar baz", "foo\n\nbar baz", "foo bar baz"], + ["foo\f\fbar baz", "foo\f\fbar baz", "foo bar baz"], + ["foo\r\rbar baz", "foo\r\rbar baz", "foo bar baz"], + ] + + tests.forEach(function(t, i) { + var title = t[0], expectedtitle = t[1], normalizedtitle = t[2] + test(function() { + var doc = document.implementation.createHTMLDocument(title); + checkDoc(doc, expectedtitle, normalizedtitle) + }, "createHTMLDocument test " + i + ": " + t.map(function(el) { return format_value(el) })) + }) + + test(function() { + var doc = document.implementation.createHTMLDocument(); + checkDoc(doc, undefined, "") + }, "Missing title argument"); +} diff --git a/Tests/LibWeb/Text/input/wpt-import/dom/nodes/Text-constructor.html b/Tests/LibWeb/Text/input/wpt-import/dom/nodes/Text-constructor.html new file mode 100644 index 00000000000..3635fdde231 --- /dev/null +++ b/Tests/LibWeb/Text/input/wpt-import/dom/nodes/Text-constructor.html @@ -0,0 +1,11 @@ + + +Text constructor + + + + +
+ diff --git a/Tests/LibWeb/Text/input/wpt-import/html/dom/documents/dom-tree-accessors/document.title-07.html b/Tests/LibWeb/Text/input/wpt-import/html/dom/documents/dom-tree-accessors/document.title-07.html new file mode 100644 index 00000000000..f5275e48dfb --- /dev/null +++ b/Tests/LibWeb/Text/input/wpt-import/html/dom/documents/dom-tree-accessors/document.title-07.html @@ -0,0 +1,11 @@ + +Document.title and DOMImplementation.createHTMLDocument + + + +
+