Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/C/Firefox/dom/xhr/tests/   (Browser von der Mozilla Stiftung Version 136.0.1©)  Datei vom 10.2.2025 mit Größe 1 kB image not shown  

Quelle  test_sync_xhr_nested.html   Sprache: HTML

 
 products/Sources/formale Sprachen/C/Firefox/dom/xhr/tests/test_sync_xhr_nested.html


<!DOCTYPE HTML>
<!-- vim: set shiftwidth=2 tabstop=2 autoindent cindent expandtab: -->
<html>
<head>
  <script src="/tests/SimpleTest/SimpleTest.js"></script>
  <script src="/tests/SimpleTest/EventUtils.js"></script>
  <link rel="stylesheet" href="/tests/SimpleTest/test.css">
</head>
<body >
  <script type="text/javascript">
  SimpleTest.waitForExplicitFinish();

  var childXHRFinished = false;
  var xhrFinished = false;
  var subTab = null;

  function receivedInput() {
    ok(xhrFinished, "Input event should be handled after the sync xhr");
    SimpleTest.finish();
  }

  function startSlowXHR() {
    var xhr = new XMLHttpRequest();
    xhr.open("GET""slow.sjs", false);
    subTab.startSlowXHR();
    xhr.send(null);

    // Above xhr.send(null) should spin up an event loop to process the inner XHR first
    ok(childXHRFinished, "Child's XHR should be finished first");
    xhrFinished = true;
  }

  async function runTest() {
    await SpecialPowers.pushPrefEnv({
      set: [["dom.input_events.canSuspendInBCG.enabled", true]]
    });
    subTab = window.open("file_sync_xhr_nested_helper.html");
    await new Promise((r) => {
      subTab.addEventListener("load", r);
    });
    startSlowXHR();
  }

  runTest();
  </script>
</body>
</html>

Messung V0.5
C=98 H=97 G=97

¤ Dauer der Verarbeitung: 0.19 Sekunden  (vorverarbeitet)  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

Beweissystem der NASA

Beweissystem Isabelle

NIST Cobol Testsuite

Cephes Mathematical Library

Wiener Entwicklungsmethode

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.