This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.
dexter gerrit-no-reply at lists.osmocom.orgHello Harald Welte, Jenkins Builder, I'd like you to reexamine a change. Please visit https://gerrit.osmocom.org/7430 to look at the new patch set (#2). BSC_Tests: split up f_mt_call and f_mo_call The functions f_mt_call and f_mo_call establish a call, hold it for 3 sec. and tear it down again. However, there may be test situation where one wants to establish a call and then hold it in order to perform other actions. - split up the function into an _establish and _hangup part. - add a replacement f_mt_call and f_mo_call function for the already existing testcases Change-Id: I0da9cf64d10de4036eb037ef5e491bfe3088670b --- M msc/BSC_ConnectionHandler.ttcn 1 file changed, 50 insertions(+), 45 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/30/7430/2 diff --git a/msc/BSC_ConnectionHandler.ttcn b/msc/BSC_ConnectionHandler.ttcn index 72e2a4e..62eddf3 100644 --- a/msc/BSC_ConnectionHandler.ttcn +++ b/msc/BSC_ConnectionHandler.ttcn @@ -405,14 +405,12 @@ mgcp_connection_id_mss := '0'H // }; - -function f_mt_call(inout CallParameters cpars) +function f_mt_call_establish(inout CallParameters cpars) runs on BSC_ConnHdlr { var MobileIdentityLV mi; var MNCC_PDU mncc; var MgcpCommand mgcp_cmd; - var boolean respond_to_dlcx; f_bssmap_register_imsi(g_pars.imsi, g_pars.tmsi); @@ -494,45 +492,10 @@ BSSAP.send(ts_PDU_DTAP_MO(ts_ML3_MO_CC_CONNECT(cpars.transaction_id))); MNCC.receive(tr_MNCC_SETUP_cnf(cpars.mncc_callref)); - /* FIXME */ - f_sleep(3.0); - - /* Hangup by "A" side */ - MNCC.send(ts_MNCC_DISC_req(cpars.mncc_callref, valueof(ts_MNCC_cause(23)))); - BSSAP.receive(tr_PDU_DTAP_MT(tr_ML3_MT_CC_DISC(cpars.transaction_id))); - - if (false) { - /* A-side (PLMN) Release of call */ - MNCC.send(ts_MNCC_REL_req(cpars.mncc_callref, valueof(ts_MNCC_cause(42)))); - BSSAP.receive(tr_PDU_DTAP_MT(tr_ML3_MT_CC_RELEASE(cpars.transaction_id))); - BSSAP.send(ts_PDU_DTAP_MO(ts_ML3_MO_CC_REL_COMPL(cpars.transaction_id))); - } else { - /* B-side (MS) Release of call */ - BSSAP.send(ts_PDU_DTAP_MO(ts_ML3_MO_CC_RELEASE(cpars.transaction_id, '1'B, '0000000'B))); - MNCC.receive(tr_MNCC_REL_ind(cpars.mncc_callref)); - BSSAP.receive(tr_PDU_DTAP_MT(tr_ML3_MT_CC_REL_COMPL(cpars.transaction_id))); - } - - respond_to_dlcx := not (isbound(cpars.mgw_drop_dlcx) and valueof(cpars.mgw_drop_dlcx)); - - /* clearing of radio channel */ - interleave { - [] BSSAP.receive(tr_BSSMAP_ClearCommand) { - BSSAP.send(ts_BSSMAP_ClearComplete); - BSSAP.receive(BSSAP_Conn_Prim:MSC_CONN_PRIM_DISC_IND); - } - [] MGCP.receive(tr_DLCX(?)) -> value mgcp_cmd { - if (respond_to_dlcx) { - /* TODO: For one or all connections on EP? */ - MGCP.send(ts_DLCX_ACK2(mgcp_cmd.line.trans_id)); - f_create_mgcp_delete_ep(cpars.mgcp_ep); - } - } - } setverdict(pass); } -function f_mo_call(inout CallParameters cpars) +function f_mo_call_establish(inout CallParameters cpars) runs on BSC_ConnHdlr { var MobileIdentityLV mi; @@ -625,16 +588,31 @@ BSSAP.receive(tr_PDU_DTAP_MT(tr_ML3_MT_CC_CONNECT(cpars.transaction_id))); BSSAP.send(ts_PDU_DTAP_MO(ts_ML3_MO_CC_CONNECT_ACK(cpars.transaction_id))); - f_sleep(3.0); + setverdict(pass); +} - /* Hangup by "B" side */ +function f_call_hangup(inout CallParameters cpars, boolean release_by_ms) +runs on BSC_ConnHdlr { + + var MobileIdentityLV mi; + var MNCC_PDU mncc; + var MgcpCommand mgcp_cmd; + var boolean respond_to_dlcx; + MNCC.send(ts_MNCC_DISC_req(cpars.mncc_callref, valueof(ts_MNCC_cause(23)))); BSSAP.receive(tr_PDU_DTAP_MT(tr_ML3_MT_CC_DISC(cpars.transaction_id))); - /* Release of call */ - MNCC.send(ts_MNCC_REL_req(cpars.mncc_callref, valueof(ts_MNCC_cause(42)))); - BSSAP.receive(tr_PDU_DTAP_MT(tr_ML3_MT_CC_RELEASE(cpars.transaction_id))); - BSSAP.send(ts_PDU_DTAP_MO(ts_ML3_MO_CC_REL_COMPL(cpars.transaction_id))); + if (release_by_ms) { + /* B-side (MS) Release of call */ + BSSAP.send(ts_PDU_DTAP_MO(ts_ML3_MO_CC_RELEASE(cpars.transaction_id, '1'B, '0000000'B))); + MNCC.receive(tr_MNCC_REL_ind(cpars.mncc_callref)); + BSSAP.receive(tr_PDU_DTAP_MT(tr_ML3_MT_CC_REL_COMPL(cpars.transaction_id))); + } else { + /* A-side (PLMN) Release of call */ + MNCC.send(ts_MNCC_REL_req(cpars.mncc_callref, valueof(ts_MNCC_cause(42)))); + BSSAP.receive(tr_PDU_DTAP_MT(tr_ML3_MT_CC_RELEASE(cpars.transaction_id))); + BSSAP.send(ts_PDU_DTAP_MO(ts_ML3_MO_CC_REL_COMPL(cpars.transaction_id))); + } respond_to_dlcx := not (isbound(cpars.mgw_drop_dlcx) and valueof(cpars.mgw_drop_dlcx)); @@ -652,6 +630,33 @@ } } } + + setverdict(pass); +} + +function f_mt_call(inout CallParameters cpars) +runs on BSC_ConnHdlr { + + f_mt_call_establish(cpars); + + /* Hold the call for some time */ + f_sleep(3.0); + + f_call_hangup(cpars, true); + + setverdict(pass); +} + +function f_mo_call(inout CallParameters cpars) +runs on BSC_ConnHdlr { + + f_mo_call_establish(cpars); + + /* Hold the call for some time */ + f_sleep(3.0); + + f_call_hangup(cpars, false); + setverdict(pass); } -- To view, visit https://gerrit.osmocom.org/7430 To unsubscribe, visit https://gerrit.osmocom.org/settings Gerrit-MessageType: newpatchset Gerrit-Change-Id: I0da9cf64d10de4036eb037ef5e491bfe3088670b Gerrit-PatchSet: 2 Gerrit-Project: osmo-ttcn3-hacks Gerrit-Branch: master Gerrit-Owner: dexter <pmaier at sysmocom.de> Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org> Gerrit-Reviewer: Jenkins Builder