tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

websocket_worker_helpers.js (537B)


      1 // This file expects websocket_helpers.js in the same scope.
      2 /* import-globals-from websocket_helpers.js */
      3 
      4 function feedback() {
      5  postMessage({
      6    type: "feedback",
      7    msg:
      8      "executing test: " +
      9      (current_test + 1) +
     10      " of " +
     11      tests.length +
     12      " tests.",
     13  });
     14 }
     15 
     16 function ok(status, msg) {
     17  postMessage({ type: "status", status: !!status, msg });
     18 }
     19 
     20 function is(a, b, msg) {
     21  ok(a === b, msg);
     22 }
     23 
     24 function isnot(a, b, msg) {
     25  ok(a != b, msg);
     26 }
     27 
     28 function finish() {
     29  postMessage({ type: "finish" });
     30 }