aboutsummaryrefslogtreecommitdiffstats
path: root/hnbgw
diff options
context:
space:
mode:
authorDaniel Willmann <dwillmann@sysmocom.de>2022-02-22 16:47:06 +0100
committerDaniel Willmann <dwillmann@sysmocom.de>2022-02-22 17:22:54 +0100
commit37c877fd1ecf2bf73bd88273a5a9157eb5091122 (patch)
tree377896e2d88e45847b065e2921346b508abae715 /hnbgw
parentcd8b71c4fa3c33868dc1d1db94a73be972d0f5b7 (diff)
hnbgw: Test behaviour when CRCX times out
Diffstat (limited to 'hnbgw')
-rw-r--r--hnbgw/HNBGW_Tests.ttcn49
1 files changed, 49 insertions, 0 deletions
diff --git a/hnbgw/HNBGW_Tests.ttcn b/hnbgw/HNBGW_Tests.ttcn
index 314b0dfd..7b9a49c9 100644
--- a/hnbgw/HNBGW_Tests.ttcn
+++ b/hnbgw/HNBGW_Tests.ttcn
@@ -979,6 +979,54 @@ testcase TC_rab_release() runs on test_CT {
vc_conn.done;
}
+friend function f_tc_rab_assign_mgcp_to(charstring id, TestHdlrParams pars) runs on ConnHdlr {
+ var MgcpCommand mgcp_cmd;
+ var RANAP_PDU tx;
+ var template RAB_SetupOrModifyList rab_sml;
+ timer T := 15.0;
+
+ T.start;
+ f_init_handler(pars);
+ f_create_mgcp_expect(ExpectCriteria:{omit,omit,omit});
+
+ tx := f_build_initial_ue(g_pars);
+ f_iuh2iu_connect(tx);
+
+
+ /* Send RAB Assignment Request */
+ rab_sml := ts_RAB_SML(t_RAB_id(23), f_ts_RAB_TLA(pars.mgcp_pars.cn_rtp_ip), t_RAB_binding_port(pars.mgcp_pars.cn_rtp_port));
+ tx := valueof(ts_RANAP_RabAssReq(rab_sml));
+ BSSAP.send(tx);
+
+ /* Ignore MGCP CRCX */
+ alt {
+ [] MGCP.receive(tr_CRCX) -> value mgcp_cmd {
+ log("Ignoreing CRCX1", mgcp_cmd);
+ repeat;
+ }
+ [] BSSAP.receive(tr_RANAP_IuReleaseRequest(?)) { }
+ [] T.timeout {
+ setverdict(fail, "Timeout waiting for IuRelease");
+ }
+ }
+
+ /* Send Iu Release */
+ tx := valueof(ts_RANAP_IuReleaseCommand(ts_RanapCause_om_intervention));
+ f_iu2iuh(tx);
+
+ tx := valueof(ts_RANAP_IuReleaseComplete());
+ f_iuh2iu(tx);
+}
+
+testcase TC_rab_assign_mgcp_to() runs on test_CT {
+ var ConnHdlr vc_conn;
+ f_init();
+ f_start_hnbs();
+
+ vc_conn := f_start_handler_with_pars(refers(f_tc_rab_assign_mgcp_to), t_pars(6));
+ vc_conn.done;
+}
+
/* Create an Iuh connection; send InitialUE; transceive data both directions */
friend function f_tc_ranap_bidir(charstring id, TestHdlrParams pars) runs on ConnHdlr {
f_init_handler(pars);
@@ -1059,6 +1107,7 @@ control {
execute(TC_rab_assignment());
execute(TC_rab_release());
execute(TC_rab_assign_fail());
+ execute(TC_rab_assign_mgcp_to());
execute(TC_ranap_cs_mo_disconnect());
execute(TC_ranap_ps_mo_disconnect());
}