tor-browser

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

object-not-found-adds-entry.html (1288B)


      1 <!DOCTYPE html>
      2 <html>
      3 <head>
      4 <meta charset="utf-8" />
      5 <title>This test validates that object resource emit resource timing entries.</title>
      6 <link rel="author" title="Google" href="http://www.google.com/" />
      7 <link rel="help" href="https://www.w3.org/TR/resource-timing-2/#sec-performanceresourcetiming"/>
      8 <script src="/resources/testharness.js"></script>
      9 <script src="/resources/testharnessreport.js"></script>
     10 <script src="resources/entry-invariants.js"></script>
     11 <script src="resources/resource-loaders.js"></script>
     12 </head>
     13 <body>
     14 <script>
     15 const load_image_object = async path => {
     16  return load.object(path, "image/png");
     17 }
     18 
     19 const load_null_object = async path => {
     20  return load.object(path, null);
     21 }
     22 
     23 attribute_test(
     24  load_null_object, "resources/status-code.py?status=200&type=none",
     25  invariants.assert_tao_pass_no_redirect_http,
     26  "Verify that a 200 null-typed object emits an entry.");
     27 
     28 attribute_test(
     29  load_null_object, "resources/status-code.py?status=404&type=none",
     30  invariants.assert_tao_pass_no_redirect_http,
     31  "Verify that a 404 null-typed object emits an entry.");
     32 
     33 attribute_test(
     34  load_image_object, "resources/status-code.py?status=404&type=img",
     35  invariants.assert_tao_pass_no_redirect_http,
     36  "Verify that a 404 img-typed object emits an entry.");
     37 </script>