wpt icon indicating copy to clipboard operation
wpt copied to clipboard

DOMParser: Tweak tests for interface of returned document

Open emilio opened this issue 6 months ago • 5 comments

See https://github.com/whatwg/html/issues/11372. This matches all browsers.

emilio avatar Jun 11 '25 21:06 emilio

Yeah, as-is this would require specification changes. Which we should probably make, but figuring out how to solve this was somewhat non-trivial I believe.

annevk avatar Jun 12 '25 07:06 annevk

@domenic @annevk Ok I just removed those tests for now. Those tests would also not be correct if we removed the XMLDocument interface (because they would do instanceof undefined).

emilio avatar Jun 13 '25 08:06 emilio

(instanceof Document is tested in checkMetadata)

emilio avatar Jun 13 '25 08:06 emilio

Per https://dom.spec.whatwg.org/#xmldocument we do define that XMLDocument exists. So we should go with the original approach and update the specification to match.

annevk avatar Jun 13 '25 13:06 annevk

Alright, done!

emilio avatar Jun 13 '25 14:06 emilio