Source code
Revision control
Copy as Markdown
Other Tools
Test Info:
- This WPT test may be referenced by the following Test IDs:
- /shadow-dom/declarative/tentative/shadowrootadoptedstylesheets/shadowrootadoptedstylesheets-document-parse-crash.html - WPT Dashboard Interop Dashboard
<!DOCTYPE html>
<html>
<head>
<title>shadowrootadoptedstylesheets does not crash in Document.parseHTMLUnsafe</title>
<meta name="author" title="Kurt Catti-Schmidt" href="mailto:kschmi@microsoft.com" />
</head>
<body>
<script>
const new_document = Document.parseHTMLUnsafe(
"<div id='host'>" +
"<template shadowrootmode='open' shadowrootadoptedstylesheets='foo'>" +
"<span id='test_element'>Test content</span>" +
"</template>" +
"</div>"
);
</script>
<p>Test passes if there is no crash.</p>
</body>
</html>