bsc: move as_Media arg fail_on_dlcx to pars
Prepare to use fail_on_dlcx in a new test case. Instead of dragging the parameter through lots of function calls, just add it to pars. Related: OS#5787 Change-Id: I6f0c4ce543724cc6f18bae9fc2b480f5818db8b7
This commit is contained in:
parent
7a8594a85a
commit
735b47cc4f
|
@ -6878,7 +6878,7 @@ private function f_tc_ho_in_fail_no_detect(charstring id) runs on MSC_ConnHdlr {
|
|||
|
||||
f_create_mgcp_expect(ExpectCriteria:{omit,omit,omit});
|
||||
f_MscConnHdlr_init(g_pars.media_nr, "127.0.0.2", "127.0.0.3", FR_AMR);
|
||||
activate(as_Media(fail_on_dlcx := false));
|
||||
activate(as_Media());
|
||||
|
||||
BSSAP.send(ts_BSSAP_Conn_Req(g_pars.sccp_addr_bsc, g_pars.sccp_addr_msc,
|
||||
f_gen_handover_req()));
|
||||
|
@ -6968,7 +6968,7 @@ private function f_tc_ho_in_fail_no_detect2(charstring id) runs on MSC_ConnHdlr
|
|||
|
||||
f_create_mgcp_expect(ExpectCriteria:{omit,omit,omit});
|
||||
f_MscConnHdlr_init(g_pars.media_nr, "127.0.0.2", "127.0.0.3", FR_AMR);
|
||||
activate(as_Media(fail_on_dlcx := false));
|
||||
activate(as_Media());
|
||||
|
||||
BSSAP.send(ts_BSSAP_Conn_Req(g_pars.sccp_addr_bsc, g_pars.sccp_addr_msc,
|
||||
f_gen_handover_req()));
|
||||
|
@ -7022,6 +7022,8 @@ testcase TC_ho_in_fail_no_detect2() runs on test_CT {
|
|||
var MSC_ConnHdlr vc_conn;
|
||||
var TestHdlrParams pars := f_gen_test_hdlr_pars();
|
||||
|
||||
pars.fail_on_dlcx := false;
|
||||
|
||||
f_init(1, true);
|
||||
f_sleep(1.0);
|
||||
|
||||
|
@ -11556,7 +11558,7 @@ private function f_TC_lost_sdcch_during_assignment(charstring id) runs on MSC_Co
|
|||
/* we should now have a COMPL_L3 at the MSC */
|
||||
|
||||
f_create_mgcp_expect(ExpectCriteria:{omit,omit,omit});
|
||||
activate(as_Media_mgw(fail_on_dlcx := false));
|
||||
activate(as_Media_mgw());
|
||||
|
||||
var RslChannelNr chan_nr := { u := { ch0 := RSL_CHAN_NR_Bm_ACCH }, tn := 1 };
|
||||
f_rslem_register(0, chan_nr);
|
||||
|
@ -11604,6 +11606,8 @@ testcase TC_lost_sdcch_during_assignment() runs on test_CT {
|
|||
var TestHdlrParams pars := f_gen_test_hdlr_pars();
|
||||
var MSC_ConnHdlr vc_conn;
|
||||
|
||||
pars.fail_on_dlcx := false;
|
||||
|
||||
f_init(1, true);
|
||||
f_sleep(1.0);
|
||||
|
||||
|
|
|
@ -442,7 +442,7 @@ runs on MSC_ConnHdlr return template MGCP_RecvFrom {
|
|||
/* altstep for handling of MGCP media related commands. Activated by as_Media() to test
|
||||
* MGW level media handling */
|
||||
|
||||
altstep as_Media_mgw(boolean norepeat := false, boolean fail_on_dlcx := true) runs on MSC_ConnHdlr {
|
||||
altstep as_Media_mgw(boolean norepeat := false) runs on MSC_ConnHdlr {
|
||||
var MgcpCommand mgcp_cmd;
|
||||
var template MgcpResponse mgcp_resp;
|
||||
var MGCP_RecvFrom mrf;
|
||||
|
@ -496,20 +496,20 @@ altstep as_Media_mgw(boolean norepeat := false, boolean fail_on_dlcx := true) ru
|
|||
}
|
||||
}
|
||||
|
||||
[fail_on_dlcx and g_pars.aoip] MGCP.receive(tr_DLCX) {
|
||||
[g_pars.fail_on_dlcx and g_pars.aoip] MGCP.receive(tr_DLCX) {
|
||||
setverdict(fail, "Unexpected DLCX received");
|
||||
}
|
||||
|
||||
[fail_on_dlcx and not g_pars.aoip] MGCP_MULTI.receive(tr_MGCP_RecvFrom_any(msg_dlcx)) {
|
||||
[g_pars.fail_on_dlcx and not g_pars.aoip] MGCP_MULTI.receive(tr_MGCP_RecvFrom_any(msg_dlcx)) {
|
||||
setverdict(fail, "Unexpected DLCX received");
|
||||
}
|
||||
}
|
||||
|
||||
/* Altsteps for handling of media related commands. Can be activated by a given
|
||||
* test case if it expects to see media related handling (i.e. voice calls) */
|
||||
altstep as_Media(boolean fail_on_dlcx := true) runs on MSC_ConnHdlr {
|
||||
altstep as_Media() runs on MSC_ConnHdlr {
|
||||
[] as_Media_ipacc();
|
||||
[] as_Media_mgw(fail_on_dlcx := fail_on_dlcx);
|
||||
[] as_Media_mgw();
|
||||
}
|
||||
|
||||
type port Coord_PT message
|
||||
|
@ -759,7 +759,8 @@ type record TestHdlrParams {
|
|||
boolean expect_ho_fail,
|
||||
boolean expect_ho_fail_lchan_est,
|
||||
boolean inter_bsc_ho_in__ho_req_in_initial_sccp_cr,
|
||||
boolean ignore_mgw_mdcx
|
||||
boolean ignore_mgw_mdcx,
|
||||
boolean fail_on_dlcx
|
||||
};
|
||||
|
||||
/* Note: Do not use valueof() to get a value of this template, use
|
||||
|
@ -806,7 +807,8 @@ template (value) TestHdlrParams t_def_TestHdlrPars := {
|
|||
expect_ho_fail := false,
|
||||
expect_ho_fail_lchan_est := false,
|
||||
inter_bsc_ho_in__ho_req_in_initial_sccp_cr := true,
|
||||
ignore_mgw_mdcx := false
|
||||
ignore_mgw_mdcx := false,
|
||||
fail_on_dlcx := true
|
||||
}
|
||||
|
||||
function f_create_chan_and_exp(template (present) PDU_BSSAP exp_l3_compl := ?)
|
||||
|
|
Loading…
Reference in New Issue