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

Quelle  url_exceptions_worker.js   Sprache: JAVA

 
function ok(a, msg) {
  postMessage({ type: "status", status: !!a, msg });
}

onmessage = function () {
  // URL.href throws
  var url = new URL("http://www.example.com");
  ok(url, "URL created");

  var status = false;
  try {
    url.href = "42";
  } catch (e) {
    status = true;
  }
  ok(status, "url.href = 42 should throw");

  url.href = "http://www.example.org";
  ok(true"url.href should not throw");

  status = false;
  try {
    new URL("42");
  } catch (e) {
    status = true;
  }
  ok(status, "new URL(42) should throw");

  status = false;
  try {
    new URL("http://www.example.com", "42");
  } catch (e) {
    status = true;
  }
  ok(status, "new URL(something, 42) should throw");

  postMessage({ type: "finish" });
};

Messung V0.5
C=90 H=100 G=95

¤ Dauer der Verarbeitung: 0.1 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.