| OLD | NEW | 
|---|
| 1 <html> | 1 <html> | 
| 2 <head> | 2 <head> | 
| 3   <script type="text/javascript" src="webrtc_test_utilities.js"></script> | 3   <script type="text/javascript" src="webrtc_test_utilities.js"></script> | 
| 4   <script type="text/javascript" src="webrtc_test_audio.js"></script> | 4   <script type="text/javascript" src="webrtc_test_audio.js"></script> | 
| 5   <script type="text/javascript"> | 5   <script type="text/javascript"> | 
| 6   $ = function(id) { | 6   $ = function(id) { | 
| 7     return document.getElementById(id); | 7     return document.getElementById(id); | 
| 8   }; | 8   }; | 
| 9 | 9 | 
| 10   var gFirstConnection = null; | 10   var gFirstConnection = null; | 
| (...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 137     navigator.webkitGetUserMedia({audio: true, video: true}, | 137     navigator.webkitGetUserMedia({audio: true, video: true}, | 
| 138         addStreamToBothConnectionsAndNegotiate, printGetUserMediaError); | 138         addStreamToBothConnectionsAndNegotiate, printGetUserMediaError); | 
| 139     waitForVideo('remote-view-1'); | 139     waitForVideo('remote-view-1'); | 
| 140     waitForVideo('remote-view-2'); | 140     waitForVideo('remote-view-2'); | 
| 141   } | 141   } | 
| 142 | 142 | 
| 143   // Test that we can't setup a call with an unsupported video codec | 143   // Test that we can't setup a call with an unsupported video codec | 
| 144   function negotiateUnsupportedVideoCodec() { | 144   function negotiateUnsupportedVideoCodec() { | 
| 145     createConnections(null); | 145     createConnections(null); | 
| 146     transformSdp = removeVideoCodec; | 146     transformSdp = removeVideoCodec; | 
| 147     navigator.webkitGetUserMedia({audio: true, video: true}, |  | 
| 148         addStreamToBothConnectionsAndNegotiate, printGetUserMediaError); |  | 
| 149     onLocalDescriptionError = function(error) { | 147     onLocalDescriptionError = function(error) { | 
| 150       var expectedMsg = 'Failed to set local offer sdp:' + | 148       var expectedMsg = 'Failed to set local offer sdp:' + | 
| 151           ' Session error code: ERROR_CONTENT. Session error description:' + | 149           ' Session error code: ERROR_CONTENT. Session error description:' + | 
| 152               ' Failed to set video receive codecs..'; | 150               ' Failed to set video receive codecs..'; | 
| 153       expectEquals(expectedMsg, error); | 151       expectEquals(expectedMsg, error); | 
| 154 | 152 | 
| 155       // Got the right message, test succeeded. | 153       // Got the right message, test succeeded. | 
| 156       document.title = 'OK'; | 154       document.title = 'OK'; | 
| 157     }; | 155     }; | 
|  | 156     navigator.webkitGetUserMedia({audio: true, video: true}, | 
|  | 157         addStreamToBothConnectionsAndNegotiate, printGetUserMediaError); | 
| 158   } | 158   } | 
| 159 | 159 | 
| 160   // Test that we can't setup a call if one peer does not support encryption | 160   // Test that we can't setup a call if one peer does not support encryption | 
| 161   function negotiateNonCryptoCall() { | 161   function negotiateNonCryptoCall() { | 
| 162     createConnections(null); | 162     createConnections(null); | 
| 163     transformSdp = removeCrypto; | 163     transformSdp = removeCrypto; | 
| 164     navigator.webkitGetUserMedia({audio: true, video: true}, |  | 
| 165         addStreamToBothConnectionsAndNegotiate, printGetUserMediaError); |  | 
| 166     onLocalDescriptionError = function(error) { | 164     onLocalDescriptionError = function(error) { | 
| 167       var expectedMsg = 'Failed to set local offer sdp:' + | 165       var expectedMsg = 'Failed to set local offer sdp:' + | 
| 168           ' Called with a SDP without crypto enabled.'; | 166           ' Called with a SDP without crypto enabled.'; | 
| 169       expectEquals(expectedMsg, error); | 167       expectEquals(expectedMsg, error); | 
| 170 | 168 | 
| 171       // Got the right message, test succeeded. | 169       // Got the right message, test succeeded. | 
| 172       document.title = 'OK'; | 170       document.title = 'OK'; | 
| 173     }; | 171     }; | 
|  | 172     navigator.webkitGetUserMedia({audio: true, video: true}, | 
|  | 173         addStreamToBothConnectionsAndNegotiate, printGetUserMediaError); | 
| 174   } | 174   } | 
| 175 | 175 | 
| 176   // Test that we can negotiate a call with an SDP offer that includes a | 176   // Test that we can negotiate a call with an SDP offer that includes a | 
| 177   // b=AS:XX line to control audio and video bandwidth | 177   // b=AS:XX line to control audio and video bandwidth | 
| 178   function negotiateOfferWithBLine() { | 178   function negotiateOfferWithBLine() { | 
| 179     createConnections(null); | 179     createConnections(null); | 
| 180     transformSdp = addBandwithControl; | 180     transformSdp = addBandwithControl; | 
| 181     navigator.webkitGetUserMedia({audio: true, video: true}, | 181     navigator.webkitGetUserMedia({audio: true, video: true}, | 
| 182         addStreamToBothConnectionsAndNegotiate, printGetUserMediaError); | 182         addStreamToBothConnectionsAndNegotiate, printGetUserMediaError); | 
| 183     waitForVideo('remote-view-1'); | 183     waitForVideo('remote-view-1'); | 
| (...skipping 621 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 805       <td><canvas width="320" height="240" id="remote-view-2-canvas" | 805       <td><canvas width="320" height="240" id="remote-view-2-canvas" | 
| 806           style="display:none"></canvas></td> | 806           style="display:none"></canvas></td> | 
| 807       <td><canvas width="320" height="240" id="remote-view-3-canvas" | 807       <td><canvas width="320" height="240" id="remote-view-3-canvas" | 
| 808           style="display:none"></canvas></td> | 808           style="display:none"></canvas></td> | 
| 809       <td><canvas width="320" height="240" id="remote-view-4-canvas" | 809       <td><canvas width="320" height="240" id="remote-view-4-canvas" | 
| 810           style="display:none"></canvas></td> | 810           style="display:none"></canvas></td> | 
| 811     </tr> | 811     </tr> | 
| 812   </table> | 812   </table> | 
| 813 </body> | 813 </body> | 
| 814 </html> | 814 </html> | 
| OLD | NEW | 
|---|