RESOLVED FIXED 25111
document.implementation.createDocument is too lenient
https://bugs.webkit.org/show_bug.cgi?id=25111
Summary document.implementation.createDocument is too lenient
Eric Seidel (no email)
Reported 2009-04-09 03:19:02 PDT
document.implementation.createDocument is too lenient This was discovered while writing a test for bug 25096 (fast/dom/DOMImplementation/createDocument-namespace-err.html) I copied fast/dom/Document/resources/createElementNS-namespace-err.js which was written as part of bug 16833. Our failures: FAIL createDocument(, null, null) FAIL createDocument(null, null, null) FAIL createDocument(null, "", null) FAIL createDocument("", null, null) FAIL createDocument("", "", null) (No message means that we didn't throw an exception when one was expected... the test could be improved to display that.) FF behavior: FAIL createDocument(, null, null); expected INVALID_CHARACTER_ERR, threw NAMESPACE_ERR FAIL createDocument(null, null, null) FAIL createDocument(null, "", null) FAIL createDocument("", null, null); expected INVALID_CHARACTER_ERR, threw NAMESPACE_ERR FAIL createDocument("", "", null)
Attachments
Eric Seidel (no email)
Comment 1 2009-04-09 03:28:55 PDT
Rob Buis
Comment 2 2013-07-04 09:14:13 PDT
When I read DOM4 it seems lenient too: http://dom.spec.whatwg.org/#dom-domimplementation-createdocument Whereas DOM2/3 was strict indeed: http://www.w3.org/TR/DOM-Level-3-Core/core.html#Level-2-Core-DOM-createDocument NAMESPACE_ERR: if the qualifiedName is null and the namespaceURI is different from null. FF latest version seem to be lenient like us, for the given 5 subtests it matches WebKit: FAIL createDocument(, null, null) FAIL createDocument(null, null, null) FAIL createDocument(null, "", null) FAIL createDocument("", null, null) FAIL createDocument("", "", null) Should we close the bug?
Lucas Forschler
Comment 3 2019-02-06 09:04:06 PST
Mass moving XML DOM bugs to the "DOM" Component.
Ahmad Saleem
Comment 4 2022-07-21 15:41:51 PDT
Safari 15.6 has full coverage of these in WPT: https://wpt.fyi/results/dom/nodes?label=master&label=experimental&aligned&q=createdocument Is there anything needed more here? Thanks!
Ryosuke Niwa
Comment 5 2022-07-21 17:02:36 PDT
Neat. We're the only engine to pass all the tests even.
Note You need to log in before you can comment on or make changes to this bug.