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

SSL test_websocket_http2.html   Interaktion und
PortierbarkeitHTML

 
 products/Sources/formale Sprachen/C/Firefox/dom/websocket/tests/test_websocket_http2.html


<!DOCTYPE HTML>
<html>
<head>
  <title>Basic HTTP/2 WebSocket test</title>
  <script src="/tests/SimpleTest/SimpleTest.js"></script>
  <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
</head>

<body onload="testWebSocket()">
<p id="display"></p>
<div id="content" style="display: none">
</div>
<pre id="test">
<script class="testbody" type="text/javascript">

const kUrl = "wss://example.com";
const data = "123456789ABCDEF";
let ws;

function testWebSocket() {
  ws = new WebSocket(kUrl, "test");

  ws.onopen = function() {
    ok(true, "onopen is called");
    ws.send(data);
  };

  ws.onmessage = function(e) {
    if (e.data instanceof Blob) {
        let reader = new FileReader();
        reader.onload = function(event) {
            is(data, event.target.result, "data should be the same");
            ws.close();
        };
        reader.readAsText(e.data);
    } else {
      is(data, e.data, "data should be the same");
      ws.close();
    }
  };

  ws.onerror = function() {
    ok(false, "onerror() should not have been called!");
    SimpleTest.executeSoon(SimpleTest.finish);
  };

  ws.onclose = function(e) {
    ok(e.wasClean, "ws closed cleanly");
    SimpleTest.executeSoon(SimpleTest.finish);
  };
}

SimpleTest.waitForExplicitFinish();

</script>
</pre>
</body>
</html>

Messung V0.5
C=93 H=92 G=92

¤ Diese beiden folgenden Angebotsgruppen bietet das Unternehmen0.21Angebot  Wie Sie bei der Firma Beratungs- und Dienstleistungen beauftragen können  ¤

*Eine klare Vorstellung vom Zielzustand






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.