tor-browser

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

getusermedia.https.html (809B)


      1 <!doctype html>
      2 <meta charset=utf-8>
      3 <title>getUserMedia</title>
      4 <script src="/resources/testharness.js"></script>
      5 <script src="/resources/testharnessreport.js"></script>
      6 <script>
      7 "use strict";
      8 
      9  [
     10    { video: { pan: { min: 1 } } },
     11    { video: { pan: { max: 1 } } },
     12    { video: { pan: { exact: 1 } } },
     13    { video: { tilt: { min: 1 } } },
     14    { video: { tilt: { max: 1 } } },
     15    { video: { tilt: { exact: 1 } } },
     16    { video: { zoom: { min: 1 } } },
     17    { video: { zoom: { max: 1 } } },
     18    { video: { zoom: { exact: 1 } } }
     19  ].forEach(constraints =>
     20    promise_test(t => {
     21      const promise = navigator.mediaDevices.getUserMedia(constraints);
     22      return promise_rejects_js(t, TypeError, promise);
     23    }, `getUserMedia(${JSON.stringify(constraints)}) must fail with TypeError`)
     24  );
     25 
     26 </script>