Index: third_party/WebKit/LayoutTests/external/wpt/dom/nodes/Document-constructor-svg.svg |
diff --git a/third_party/WebKit/LayoutTests/external/wpt/dom/nodes/Document-constructor.html b/third_party/WebKit/LayoutTests/external/wpt/dom/nodes/Document-constructor-svg.svg |
similarity index 75% |
copy from third_party/WebKit/LayoutTests/external/wpt/dom/nodes/Document-constructor.html |
copy to third_party/WebKit/LayoutTests/external/wpt/dom/nodes/Document-constructor-svg.svg |
index 11549da4ab47dd5c5ff5c1f3e661474bd023ba84..28aaf16bdcd182f0a754e197d9b250475e59c762 100644 |
--- a/third_party/WebKit/LayoutTests/external/wpt/dom/nodes/Document-constructor.html |
+++ b/third_party/WebKit/LayoutTests/external/wpt/dom/nodes/Document-constructor-svg.svg |
@@ -1,13 +1,12 @@ |
-<!doctype html> |
-<meta charset=windows-1252> |
+<?xml version="1.0" encoding="windows-1252"?> |
<!-- Using windows-1252 to ensure that new Document() doesn't inherit utf-8 |
from the parent document. --> |
+<svg xmlns="http://www.w3.org/2000/svg" xmlns:html="http://www.w3.org/1999/xhtml" |
+ width="100%" height="100%" viewBox="0 0 800 600"> |
<title>Document constructor</title> |
-<link rel=help href="https://dom.spec.whatwg.org/#dom-document"> |
-<script src="/resources/testharness.js"></script> |
-<script src="/resources/testharnessreport.js"></script> |
-<div id="log"></div> |
-<script> |
+<html:script src="/resources/testharness.js"></html:script> |
+<html:script src="/resources/testharnessreport.js"></html:script> |
+<html:script><![CDATA[ |
test(function() { |
var doc = new Document(); |
assert_true(doc instanceof Node, "Should be a Node"); |
@@ -33,6 +32,7 @@ test(function() { |
assert_equals(doc.compatMode, "CSS1Compat"); |
assert_equals(doc.characterSet, "UTF-8"); |
assert_equals(doc.contentType, "application/xml"); |
+ assert_equals(doc.origin, document.origin); |
assert_equals(doc.createElement("DIV").localName, "DIV"); |
}, "new Document(): metadata") |
@@ -42,12 +42,6 @@ test(function() { |
assert_equals(doc.charset, "UTF-8", "charset"); |
assert_equals(doc.inputEncoding, "UTF-8", "inputEncoding"); |
}, "new Document(): characterSet aliases") |
+]]></html:script> |
+</svg> |
-test(function() { |
- var doc = new Document(); |
- var a = doc.createElement("a"); |
- // In UTF-8: 0xC3 0xA4 |
- a.href = "http://example.org/?\u00E4"; |
- assert_equals(a.href, "http://example.org/?%C3%A4"); |
-}, "new Document(): URL parsing") |
-</script> |