1 <!DOCTYPE HTML PUBLIC
"-//IETF//DTD HTML//EN">
4 <script src=
"../../resources/js-test.js"></script>
8 description("Tests RTCPeerConnection onnegotiationneeded.");
14 testFailed('Stream generation failed.');
18 function getUserMedia(dictionary
, callback
) {
20 navigator
.webkitGetUserMedia(dictionary
, callback
, error
);
22 testFailed('webkitGetUserMedia threw exception :' + e
);
27 function onNegotiationNeeded(event
) {
28 testPassed('onNegotiationNeeded was called.');
33 function gotStream(s
) {
34 testPassed('Got a stream.');
37 pc
= new webkitRTCPeerConnection(null, null);
38 pc
.onnegotiationneeded
= onNegotiationNeeded
;
43 getUserMedia({audio
:true, video
:true}, gotStream
);
45 window
.jsTestIsAsync
= true;
46 window
.successfullyParsed
= true;