Files
sousa-gecko/testing/web-platform/tests/dom/nodes/replaceWith-document-element-crash.html
T
Euclid Ye e455ec65b7 Bug 2035712 [wpt PR 59476] - script: Guard against stale dirty_root when replacing the document element, a=testonly
Automatic update from web-platform-tests
replaceWith <document> in a cycle should not panic

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>

--
use LF instead of CRLF

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>

--

wpt-commits: 252175f154f0d83b783bc54044b6385a271c0061, b4636ea54ebd65acf94661a34a3d4f399a58b67c
wpt-pr: 59476
2026-05-08 08:33:51 +00:00

11 lines
402 B
HTML

<!DOCTYPE html>
<meta name="assert" content="Test replaceWith in a cycle">
<link rel=help href="https://github.com/servo/servo/issues/35698">
<link rel="author" title="Euclid Ye" href="mailto:yezhizhenjiakang@gmail.com">
<script>
var oldRoot = document.documentElement;
var newRoot = document.createElement("html");
oldRoot.replaceWith(newRoot);
newRoot.replaceWith(oldRoot);
</script>