tor-browser

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

eventsource-onmessage.htm (642B)


      1 <!doctype html>
      2 <html>
      3  <head>
      4    <title>dedicated worker - EventSource: onmessage</title>
      5    <script src="/resources/testharness.js"></script>
      6    <script src="/resources/testharnessreport.js"></script>
      7  </head>
      8  <body>
      9    <div id="log"></div>
     10    <script>
     11      var test = async_test()
     12      test.step(function() {
     13        var worker = new Worker('eventsource-onmesage.js')
     14        worker.onmessage = function(e) {
     15          test.step(function() {
     16            assert_true(e.data[0], e.data[1])
     17            assert_equals(e.data[1], "data", 'e.data')
     18          })
     19          test.done()
     20        }
     21      })
     22    </script>
     23  </body>
     24 </html>