Bug 824923 - Stablize WebRTC mochitests against Javascript exceptions to prevent timeouts. r=jesup

This commit is contained in:
Henrik Skupin 2012-12-27 21:55:52 +01:00
parent 951234cefc
commit 1b3fd919f0

View File

@ -24,8 +24,14 @@ function runTest(aCallback, desktopSupportedOnly) {
ok(true, navigator.userAgent + ' currently not supported');
SimpleTest.finish();
} else {
SpecialPowers.pushPrefEnv({'set': [['media.peerconnection.enabled', true]]},
aCallback);
SpecialPowers.pushPrefEnv({'set': [['media.peerconnection.enabled', true]]}, function () {
try {
aCallback();
}
catch (err) {
unexpectedCallbackAndFinish(err);
}
});
}
}