Truly independent web browser
Tests/LibWeb: Import WPT test for tagName after adoption
Andreas Klinge29900f58281
diff --git a/Tests/LibWeb/Text/expected/wpt-import/dom/nodes/Element-tagName-adopt.txt b/Tests/LibWeb/Text/expected/wpt-import/dom/nodes/Element-tagName-adopt.txtnew file mode 100644index 00000000000..d963be72816--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/dom/nodes/Element-tagName-adopt.txt@@ -0,0 +1,6 @@+Harness status: OK++Found 1 tests++1 Fail+Fail tagName should not be uppercased when appended to XML document\ No newline at end of filediff --git a/Tests/LibWeb/Text/input/wpt-import/dom/nodes/Element-tagName-adopt.html b/Tests/LibWeb/Text/input/wpt-import/dom/nodes/Element-tagName-adopt.htmlnew file mode 100644index 00000000000..85a7d10c4aa--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/dom/nodes/Element-tagName-adopt.html@@ -0,0 +1,18 @@+<!doctype html>+<meta charset=utf-8>+<title>Element.tagName</title>+<script src=../../resources/testharness.js></script>+<script src=../../resources/testharnessreport.js></script>+<body>+<script>+ "use strict";+ test(() => {+ const el = document.createElement("t");+ const xmlEl = document.implementation+ .createDocument("http://www.w3.org/1999/xhtml", "div", null)+ .documentElement;+ assert_equals(el.tagName, "T", "tagName should be uppercase in HTML document");+ xmlEl.appendChild(el);+ assert_equals(el.tagName, "t", "tagName should be lowercase in XML document");+ }, "tagName should not be uppercased when appended to XML document");+</script>