diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-07 19:33:14 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-07 19:33:14 +0000 |
commit | 36d22d82aa202bb199967e9512281e9a53db42c9 (patch) | |
tree | 105e8c98ddea1c1e4784a60a5a6410fa416be2de /accessible/tests/crashtests/last_test_to_unload_testsuite.xhtml | |
parent | Initial commit. (diff) | |
download | firefox-esr-36d22d82aa202bb199967e9512281e9a53db42c9.tar.xz firefox-esr-36d22d82aa202bb199967e9512281e9a53db42c9.zip |
Adding upstream version 115.7.0esr.upstream/115.7.0esr
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'accessible/tests/crashtests/last_test_to_unload_testsuite.xhtml')
-rw-r--r-- | accessible/tests/crashtests/last_test_to_unload_testsuite.xhtml | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/accessible/tests/crashtests/last_test_to_unload_testsuite.xhtml b/accessible/tests/crashtests/last_test_to_unload_testsuite.xhtml new file mode 100644 index 0000000000..9a70c41dcf --- /dev/null +++ b/accessible/tests/crashtests/last_test_to_unload_testsuite.xhtml @@ -0,0 +1,36 @@ +<?xml version="1.0"?> +<?xml-stylesheet href="chrome://global/skin" type="text/css"?> + +<window xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" + title="bug 471493 'crash [@ nsPropertyTable::GetPropertyInternal]'" + onload="shutdown();" class="reftest-wait"> + + <script type="application/javascript"> + <![CDATA[ + function shutdown() { + !SpecialPowers.Services.appinfo.accessibilityEnabled && + dump("### Error : Accessibility is expected to be enabled.\n"); + + // Force garbage collection. We try really hard to garbage collect + // everythin here to ensure that all a11y xpcom bits are shut down and + // avoid intermittent timeouts. + SpecialPowers.gc(); + SpecialPowers.forceShrinkingGC(); + SpecialPowers.forceCC(); + SpecialPowers.gc(); + SpecialPowers.forceShrinkingGC(); + SpecialPowers.forceCC(); + + if (SpecialPowers.Services.appinfo.accessibilityEnabled) { + let observe = (subject, topic, data) => { + SpecialPowers.Services.obs.removeObserver(observe, "a11y-init-or-shutdown"); + data === "0" && document.documentElement.removeAttribute("class"); + }; + SpecialPowers.Services.obs.addObserver(observe, "a11y-init-or-shutdown"); + } else { + document.documentElement.removeAttribute("class"); + } + } + ]]> + </script> +</window> |