Bug 1098193 - Part 2: Fix tests: using waiting state. r=hsinyi

This commit is contained in:
Szu-Yu Chen [:aknow] 2014-11-27 15:29:27 +08:00
parent 097654ed39
commit a1a742195c
5 changed files with 7 additions and 19 deletions

View File

@ -273,7 +273,7 @@ let emulator = (function() {
let numberInfo = prefix + number + padding.substr(number.length);
let info = {};
let states = ['ringing', 'incoming', 'active', 'held'];
let states = ["ringing", "incoming", "waiting", "active", "held"];
for (let state of states) {
info[state] = numberInfo + state;
}
@ -911,7 +911,7 @@ let emulator = (function() {
.then(() => remoteDial(inNumber))
.then(call => { inCall = call; })
.then(() => checkAll(outCall, [outCall, inCall], '', [],
[outInfo.active, inInfo.incoming]))
[outInfo.active, inInfo.waiting]))
.then(() => answer(inCall))
.then(() => checkAll(inCall, [outCall, inCall], '', [],
[outInfo.held, inInfo.active]))
@ -951,7 +951,7 @@ let emulator = (function() {
});
}
for (let state of ['ringing', 'incoming', 'active', 'held']) {
for (let state of ["ringing", "incoming", "waiting", "active", "held"]) {
addInfoState(allInfo, state);
}
@ -961,7 +961,7 @@ let emulator = (function() {
return remoteDial(inNumber)
.then(call => { newCall = call; })
.then(() => checkAll(conference, [newCall], 'connected', conferenceCalls,
allInfo.active.concat(newInfo.incoming)))
allInfo.active.concat(newInfo.waiting)))
.then(() => answer(newCall, function() {
checkState(newCall, [newCall], 'held', conferenceCalls);
}))

View File

@ -19,7 +19,6 @@ qemu = true
[test_incoming_hold_resume.js]
[test_outgoing_hold_resume.js]
[test_incoming_already_connected.js]
disabled = Bug 1098193
[test_incoming_answer_remote_hangup.js]
[test_incoming_connecting_hangup.js]
[test_incoming_connecting_remote_hangup.js]
@ -51,31 +50,20 @@ disabled = Bug 821958
[test_audiomanager_phonestate.js]
[test_outgoing_answer_radio_off.js]
[test_conference_two_calls.js]
disabled = Bug 1098193
[test_conference_add_error.js]
disabled = Bug 1098193
[test_conference_remove_error.js]
disabled = Bug 1098193
[test_conference_two_hangup_all.js]
disabled = Bug 1098193
[test_conference_two_hangup_one.js]
disabled = Bug 1098193
[test_conference_two_hold_resume.js]
disabled = Bug 1098193
[test_conference_two_remove_one.js]
disabled = Bug 1098193
[test_conference_three_hangup_one.js]
disabled = Bug 1098193
[test_conference_three_remove_one.js]
disabled = Bug 1098193
[test_conference_add_twice_error.js]
disabled = Bug 1098193
[test_outgoing_when_two_calls_on_line.js]
[test_call_presentation.js]
[test_temporary_clir.js]
[test_outgoing_error_state.js]
[test_outgoing_auto_hold.js]
disabled = Bug 1098193
[test_mmi.js]
[test_mmi_change_pin.js]
[test_mmi_call_forwarding.js]

View File

@ -26,7 +26,7 @@ function testConferenceTwoCallsTwice() {
.then(() => gRemoteDial(inNumber))
.then(call => { inCall = call; })
.then(() => gCheckAll(outCall, [outCall, inCall], '', [],
[outInfo.active, inInfo.incoming]))
[outInfo.active, inInfo.waiting]))
.then(() => gAnswer(inCall))
.then(() => gCheckAll(inCall, [outCall, inCall], '', [],
[outInfo.held, inInfo.active]))

View File

@ -43,7 +43,7 @@ function testConferenceRemoveError() {
.then(() => gRemoteDial(inNumber2))
.then(call => {inCall2 = call;})
.then(() => gCheckAll(conference, [inCall2], 'connected', [outCall, inCall],
[outInfo.active, inInfo.active, inInfo2.incoming]))
[outInfo.active, inInfo.active, inInfo2.waiting]))
.then(() => gAnswer(inCall2, function() {
gCheckState(inCall2, [inCall2], 'held', [outCall, inCall]);
}))

View File

@ -83,7 +83,7 @@ function simulateIncoming() {
emulator.runCmdWithCallback("gsm list", function(result) {
log("Call list is now: " + result);
is(result[0], "outbound to " + outNumber + " : active");
is(result[1], "inbound from " + inNumber + " : incoming");
is(result[1], "inbound from " + inNumber + " : waiting");
answerIncoming();
});
};