tor-browser

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

t009-manual.https.html (991B)


      1 <!DOCTYPE html>
      2 <html>
      3  <head>
      4    <title>Rotate the device frame around its x axis</title>
      5    <meta name=viewport content="width=device-width, maximum-scale=1.0">
      6    <script src="/resources/testharness.js"></script>
      7    <script src="/resources/testharnessreport.js"></script>
      8    <link rel="author" title="Mosquito FP7">
      9    <link rel="reviewer author" title="Zhiqiang Zhang" href="mailto:zhiqiang.zhang@intel.com"> <!-- 2013-10-12 -->
     10  </head>
     11  <body>
     12    <p>Rotate the device frame around its x axis to run the test.</p>
     13    <div id="log"></div>
     14    <script>
     15      var t1 = async_test("Beta is in [-180, 180)");
     16      var run = false;
     17      window.addEventListener("deviceorientation", function(e) {
     18        if (!run && e.beta !== null) {
     19          run = true;
     20          t1.step(function() {
     21            assert_greater_than_equal(e.beta, -180);
     22            assert_less_than(e.beta, 180);
     23          });
     24          t1.done();
     25        }
     26      }, false);
     27    </script>
     28  </body>
     29 </html>