Automatic update from web-platform-tests Serialize CDATASections in HTML documents the same as Text https://html.spec.whatwg.org/multipage/parsing.html#serialising-html-fragments Fixed: 40791925 Change-Id: I4c46e6143958cb3de9052ee51fc9756c61272cba Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6430108 Commit-Queue: Fredrik Söderquist <fs@opera.com> Reviewed-by: Mason Freed <masonf@chromium.org> Cr-Commit-Position: refs/heads/main@{#1453761} -- wpt-commits: fe92d5e9ea136e2c97e75710af6189178faff5dd wpt-pr: 52246 Differential Revision: https://phabricator.services.mozilla.com/D248753
13 lines
593 B
HTML
13 lines
593 B
HTML
<!DOCTYPE html>
|
|
<title>Serializing CDATA in an HTML document</title>
|
|
<link rel="help" href="https://html.spec.whatwg.org/multipage/parsing.html#serialising-html-fragments">
|
|
<script src="/resources/testharness.js"></script>
|
|
<script src="/resources/testharnessreport.js"></script>
|
|
<script>
|
|
test(t => {
|
|
const doc = new DOMParser().parseFromString('<svg xmlns="http://www.w3.org/2000/svg"><![CDATA[<img>]]></svg>', 'application/xml');
|
|
const el = document.adoptNode(doc.documentElement);
|
|
assert_equals(el.outerHTML, '<svg xmlns="http://www.w3.org/2000/svg"><img></svg>');
|
|
});
|
|
</script>
|