tor-browser

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

test_peerConnection_restartIceNoBundle.html (1155B)


      1 <!DOCTYPE HTML>
      2 <html>
      3 <head>
      4  <script type="application/javascript" src="pc.js"></script>
      5 </head>
      6 <body>
      7 <pre id="test">
      8 <script type="application/javascript">
      9  createHTML({
     10    bug: "906986",
     11    title: "Renegotiation: restart ice, no bundle"
     12  });
     13 
     14  var test;
     15  runNetworkTest(function (options) {
     16    options = options || { };
     17    options.bundle = false;
     18    test = new PeerConnectionTest(options);
     19 
     20    addRenegotiation(test.chain,
     21      [
     22        // causes a full, normal ice restart
     23        function PC_LOCAL_SET_OFFER_OPTION(test) {
     24          test.setOfferOptions({ iceRestart: true });
     25        },
     26        // Make sure we don't get the end of gathering racing against the
     27        // setting of the new offer
     28        function PC_LOCAL_WAIT_FOR_END_OF_TRICKLE(test) {
     29          return test.pcLocal.endOfTrickleIce;
     30        },
     31        function PC_LOCAL_SETUP_ICE_HANDLER(test) {
     32          test.pcLocal.setupIceCandidateHandler(test);
     33        },
     34      ]
     35    );
     36 
     37    test.setMediaConstraints([{audio: true}, {video: true}],
     38                             [{audio: true}, {video: true}]);
     39    return test.run();
     40  });
     41 
     42 </script>
     43 </pre>
     44 </body>
     45 </html>