mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-26 04:09:50 +00:00
Bug 1065185 - Fix crash IPC tests. r=bz
This commit is contained in:
parent
9f6dfee5c1
commit
9a78987c80
@ -55,10 +55,10 @@ SpecialPowers.pushPrefEnv({'set':[
|
||||
// Finally, poll for the new crash record.
|
||||
function tryGetCrash() {
|
||||
info("Waiting for getCrashes");
|
||||
crashMan.getCrashes().then(function (crashes) {
|
||||
crashMan.getCrashes().then(SpecialPowers.wrapCallback(function (crashes) {
|
||||
if (crashes.length) {
|
||||
is(crashes.length, 1, "There should be only one record");
|
||||
var crash = SpecialPowers.wrap(crashes[0]);
|
||||
var crash = crashes[0];
|
||||
ok(crash.isOfType(crashMan.PROCESS_TYPE_CONTENT,
|
||||
crashMan.CRASH_TYPE_CRASH),
|
||||
"Record should be a content crash");
|
||||
@ -75,7 +75,7 @@ SpecialPowers.pushPrefEnv({'set':[
|
||||
else {
|
||||
setTimeout(tryGetCrash, 1000);
|
||||
}
|
||||
}, function (err) {
|
||||
}), function (err) {
|
||||
ok(false, "Error getting crashes: " + err);
|
||||
SimpleTest.finish();
|
||||
});
|
||||
|
@ -69,7 +69,7 @@ function crashAndGetCrashServiceRecord(crashMethodName, callback) {
|
||||
// the new record.
|
||||
function tryGetCrash() {
|
||||
info("Waiting for getCrashes");
|
||||
crashMan.getCrashes().then(function (crashes) {
|
||||
crashMan.getCrashes().then(SpecialPowers.wrapCallback(function (crashes) {
|
||||
if (crashes.length) {
|
||||
is(crashes.length, 1, "There should be only one record");
|
||||
var crash = SpecialPowers.wrap(crashes[0]);
|
||||
@ -86,7 +86,7 @@ function crashAndGetCrashServiceRecord(crashMethodName, callback) {
|
||||
else {
|
||||
setTimeout(tryGetCrash, 1000);
|
||||
}
|
||||
}, function (err) {
|
||||
}), function (err) {
|
||||
ok(false, "Error getting crashes: " + err);
|
||||
SimpleTest.finish();
|
||||
});
|
||||
|
Loading…
x
Reference in New Issue
Block a user