dom/media/tests/mochitest/test_peerConnection_setLocalOfferInHaveRemoteOffer.html

Thu, 22 Jan 2015 13:21:57 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 22 Jan 2015 13:21:57 +0100
branch
TOR_BUG_9701
changeset 15
b8a032363ba2
permissions
-rw-r--r--

Incorporate requested changes from Mozilla in review:
https://bugzilla.mozilla.org/show_bug.cgi?id=1123480#c6

     1 <!DOCTYPE HTML>
     2 <html>
     3 <head>
     4   <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css"/>
     5   <script type="application/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
     6   <script type="application/javascript" src="head.js"></script>
     7   <script type="application/javascript" src="mediaStreamPlayback.js"></script>
     8   <script type="application/javascript" src="pc.js"></script>
     9   <script type="application/javascript" src="templates.js"></script>
    10 </head>
    11 <body>
    12 <pre id="test">
    13 <script type="application/javascript">
    14   createHTML({
    15     bug: "784519",
    16     title: "setLocalDescription (offer) in 'have-remote-offer'"
    17   });
    19   var test;
    20   runTest(function () {
    21     test = new PeerConnectionTest();
    22     test.setMediaConstraints([{audio: true}], [{audio: true}]);
    23     test.chain.removeAfter("PC_REMOTE_SET_REMOTE_DESCRIPTION");
    25     test.chain.append([[
    26       "PC_REMOTE_SET_LOCAL_OFFER",
    27       function (test) {
    28         test.pcRemote.setLocalDescriptionAndFail(test.pcLocal._last_offer,
    29           function(err) {
    30             is(err.name, "INVALID_STATE", "Error is INVALID_STATE");
    31             test.next();
    32           } );
    33       }
    34     ]]);
    36     test.run();
    37   });
    38 </script>
    39 </pre>
    40 </body>
    41 </html>

mercurial