tor-browser

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

404-response-with-actual-image-data.html (681B)


      1 <!DOCTYPE HTML>
      2 <meta charset="utf-8">
      3 <title>404 response with actual image data should be rendered and load event is fired</title>
      4 <script src="/resources/testharness.js"></script>
      5 <script src="/resources/testharnessreport.js"></script>
      6 
      7 <img id="img">
      8 
      9 <script>
     10  async_test(t => {
     11    var img = document.getElementById("img");
     12    img.onload = t.step_func_done(e => {
     13      assert_equals(e.type, "load", "image.onload() called");
     14    });
     15    img.onerror = t.unreached_func("image.onerror() was not supposed to be called");
     16    img.src = "404-response-with-actual-image-data.py";
     17  }, "404 response with actual image data should be rendered and load event is fired");
     18 </script>