[10743] Add content type to XmlDocument constructor based on namespace

[10743] Fix namespace in createDocument test

[10743] Remove test ini file, match returns static strings instead of DOMString.

[10743] Fix arguments to XMLDocument::new

Update failing test

[10743] Add content type to XmlDocument constructor based on namespace

[10743] Fix namespace in createDocument test

[10743] Remove test ini file, match returns static strings instead of DOMString.

[10743] Fix arguments to XMLDocument::new

Update failing test
This commit is contained in:
cjkenned 2016-04-24 10:12:15 -06:00
parent f932db34c8
commit d9128fba07
4 changed files with 14 additions and 16 deletions

View file

@ -1,9 +0,0 @@
[DOMImplementation-createDocument.html]
type: testharness
bug: https://github.com/servo/servo/issues/10743
[createDocument test 179: metadata for "http://www.w3.org/1999/xhtml","",null]
expected: FAIL
[createDocument test 180: metadata for "http://www.w3.org/2000/svg","",null]
expected: FAIL

View file

@ -123,7 +123,7 @@ test(function() {
var doc = document.implementation.createDocument(namespace, qualifiedName, doctype)
assert_equals(doc.compatMode, "CSS1Compat")
assert_equals(doc.characterSet, "UTF-8")
assert_equals(doc.contentType, namespace == htmlNamespace ? "text/html"
assert_equals(doc.contentType, namespace == htmlNamespace ? "application/xhtml+xml"
: namespace == svgNamespace ? "image/svg+xml"
: "application/xml")
assert_equals(doc.URL, "about:blank")

View file

@ -1,11 +1,11 @@
<!DOCTYPE html>
<title>document.implementation.createDocument: document.contentType === 'application/xml'</title>
<title>document.implementation.createDocument: document.contentType === 'application/xhtml+xml'</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<div id=log></div>
<script>
test(function() {
var doc = document.implementation.createDocument("http://www.w3.org/1999/xhtml", "html", null);
assert_equals(doc.contentType, "application/xml");
assert_equals(doc.contentType, "application/xhtml+xml");
});
</script>