diff options
Diffstat (limited to 'testing/web-platform/tests/editing/crashtests')
3 files changed, 98 insertions, 0 deletions
diff --git a/testing/web-platform/tests/editing/crashtests/caret-display-list-002.html b/testing/web-platform/tests/editing/crashtests/caret-display-list-002.html new file mode 100644 index 0000000000..23f0496efd --- /dev/null +++ b/testing/web-platform/tests/editing/crashtests/caret-display-list-002.html @@ -0,0 +1,35 @@ +<html class="test-wait reftest-wait"> +<style> +#a { + float: none; +} +#c { + transition-delay: 1s; +} +* { + border-style: solid inset dashed; + translate: 0px 0px; + perspective: 0em; + display: inline; + float: left; + contain: size layout paint; +} +</style> +<script> +function func_0() { + a.focus() + b.cellSpacing = "73px" + document.execCommand("indent", false) + requestAnimationFrame(() => requestAnimationFrame(() => { + document.documentElement.className = ""; + })); +} +document.addEventListener("DOMContentLoaded", () => { + window.ontransitionend = func_0 + document.execCommand("outdent", false) +}) +</script> +<details ontoggle="func_0()" open=""> +<summary id="a" contenteditable="true"> +<table id="b"> +<tr id="c"> diff --git a/testing/web-platform/tests/editing/crashtests/caret-display-list.html b/testing/web-platform/tests/editing/crashtests/caret-display-list.html new file mode 100644 index 0000000000..f7c7a740e1 --- /dev/null +++ b/testing/web-platform/tests/editing/crashtests/caret-display-list.html @@ -0,0 +1,26 @@ +<html class="test-wait reftest-wait"> +<style> +* { + backdrop-filter: hue-rotate(0deg); + offset: path('M 72 1 h 0 v 90') 0px 0rad; + mask-image: url(#x) +} +</style> +<script> +let stop = false; +function func_01() { + document.execCommand("justifyCenter", false) + document.getSelection().collapse(a) + requestAnimationFrame(() => requestAnimationFrame(() => { + if (stop) { + document.documentElement.classList = ""; + return; + } + // Ensure that we've painted at least twice. + stop = true; + func_01(); + })); +} +document.addEventListener("DOMContentLoaded", func_01) +</script> +<meter id="a" contenteditable="true">AA</meter> diff --git a/testing/web-platform/tests/editing/crashtests/designMode-caret-change.html b/testing/web-platform/tests/editing/crashtests/designMode-caret-change.html new file mode 100644 index 0000000000..be80afd4ab --- /dev/null +++ b/testing/web-platform/tests/editing/crashtests/designMode-caret-change.html @@ -0,0 +1,37 @@ +<!doctype html> +<html class="test-wait reftest-wait"> +<style> +button { + background-repeat: no-repeat; +} +*:last-child { + opacity: 0; + animation: kf ease-in, steps(65, start) 0.92 paused; + border-radius: inherit +} +@keyframes kf {} +</style> +<script> +let animationEnded = false; +let selectionChanged = false; +function maybeFinishTest() { + if (animationEnded && selectionChanged) { + requestAnimationFrame(() => requestAnimationFrame(() => { + document.documentElement.className = ""; + })); + } +} +document.addEventListener("DOMContentLoaded", () => { + document.designMode = "on" + window.onanimationend = () => { + document.execCommand("insertHTML", false, "A") + animationEnded = true; + maybeFinishTest(); + } + document.onselectionchange = () => { + document.execCommand("selectAll", false) + selectionChanged = true; + maybeFinishTest(); + } +}) +</script> |