mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-10 01:08:21 +00:00
Bug 1033833 - unbreak test_exceptions_from_jsimplemented.html. r=bz
This commit is contained in:
parent
41fc3f1755
commit
0cb75e0d47
@ -12,17 +12,18 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=923010
|
||||
/** Test for Bug 923010 **/
|
||||
try {
|
||||
var conn = new mozRTCPeerConnection();
|
||||
var candidate = new mozRTCIceCandidate({candidate: null });
|
||||
try {
|
||||
conn.createAnswer(function() {
|
||||
ok(false, "The call to createAnswer succeeded when it should have thrown");
|
||||
conn.addIceCandidate(candidate, function() {
|
||||
ok(false, "The call to addIceCandidate succeeded when it should have thrown");
|
||||
}, function() {
|
||||
ok(false, "The call to createAnswer failed when it should have thrown");
|
||||
}, { "mandatory": { "BOGUS": 5 } } )
|
||||
ok(false, "That call to createAnswer should have thrown");
|
||||
ok(false, "The call to addIceCandidate failed when it should have thrown");
|
||||
})
|
||||
ok(false, "That call to addIceCandidate should have thrown");
|
||||
} catch (e) {
|
||||
is(e.lineNumber, 16, "Exception should have been on line 16");
|
||||
is(e.lineNumber, 17, "Exception should have been on line 17");
|
||||
is(e.message,
|
||||
"createAnswer passed invalid constraints - unknown mandatory constraint: BOGUS",
|
||||
"Invalid candidate passed to addIceCandidate!",
|
||||
"Should have the exception we expect");
|
||||
}
|
||||
} catch (e) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user