content-encoding.https.html (1074B)
1 <!DOCTYPE html> 2 <html> 3 4 <head> 5 <meta charset="utf-8"> 6 <meta name="variant" , content="?pipe=gzip"> 7 <title>contentEncoding in navigation timing</title> 8 <link rel="author" title="Microsoft" href="http://www.microsoft.com/" /> 9 <link rel="help" href="http://www.w3.org/TR/navigation-timing/#sec-navigation-timing-interface" /> 10 <script src="/resources/testharness.js"></script> 11 <script src="/resources/testharnessreport.js"></script> 12 13 <script> 14 async_test(function (t) { 15 var observer = new PerformanceObserver( 16 t.step_func(function (entryList) { 17 assert_equals(entryList.getEntries()[0].contentEncoding, "gzip", 18 "Expected contentEncoding to be gzip."); 19 observer.disconnect(); 20 t.done(); 21 }) 22 ); 23 observer.observe({ entryTypes: ["navigation"] }); 24 25 }, "contentEncoding should be gzip."); 26 </script> 27 </head> 28 29 <body> 30 <h1> 31 Description</h1> 32 <p> 33 This test validates that when a html is compressed with gzip, navigation timing reports contentEncoding as gzip</p> 34 </body> 35 36 </html>