[PATCH] osmo-ttcn3-hacks[master]: bts: Add TC_ipa_crcx_mdcx_mdcx_dlcx_not_active (2x MDCX on l...

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/.

Harald Welte gerrit-no-reply at lists.osmocom.org
Sun Feb 25 16:00:49 UTC 2018


Review at  https://gerrit.osmocom.org/6901

bts: Add TC_ipa_crcx_mdcx_mdcx_dlcx_not_active (2x MDCX on lchan)

Change-Id: I58475e15958002e18cbe9d471bb5c8959bbf7bed
---
M bts/BTS_Tests.ttcn
1 file changed, 28 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/01/6901/1

diff --git a/bts/BTS_Tests.ttcn b/bts/BTS_Tests.ttcn
index 9c2e74a..cc78057 100644
--- a/bts/BTS_Tests.ttcn
+++ b/bts/BTS_Tests.ttcn
@@ -1049,6 +1049,33 @@
 	vc_conn.done;
 }
 
+/* Sequence of CRCX, 2x MDCX, DLCX */
+function f_TC_ipa_crcx_mdcx_mdcx_dlcx_not_active(charstring id) runs on ConnHdlr {
+	f_rsl_transceive(ts_RSL_IPA_CRCX(g_chan_nr), tr_RSL_IPA_CRCX_ACK(g_chan_nr, ?, ?, ?),
+			 "IPA CRCX ACK");
+	var uint32_t remote_ip := f_rnd_int(c_UINT32_MAX);
+	var uint16_t remote_port := f_rnd_int(c_UINT16_MAX);
+	var uint7_t rtp_pt2 := f_rnd_int(127);
+	var uint16_t fake_conn_id := 23; /* we're too lazy to read it out from the CRCX ACK above */
+	f_rsl_transceive(ts_RSL_IPA_MDCX(g_chan_nr, fake_conn_id, remote_ip, remote_port, rtp_pt2),
+			 tr_RSL_IPA_MDCX_ACK(g_chan_nr, ?, ?, ?, rtp_pt2),
+			 "IPA MDCX ACK");
+	/* Second MDCX */
+	remote_ip := f_rnd_int(c_UINT32_MAX);
+	remote_port := f_rnd_int(c_UINT16_MAX);
+	f_rsl_transceive(ts_RSL_IPA_MDCX(g_chan_nr, fake_conn_id, remote_ip, remote_port, rtp_pt2),
+			 tr_RSL_IPA_MDCX_ACK(g_chan_nr, ?, ?, ?, rtp_pt2),
+			 "IPA MDCX ACK");
+	f_rsl_transceive(ts_RSL_IPA_DLCX(g_chan_nr, fake_conn_id), tr_RSL_IPA_DLCX_ACK(g_chan_nr, ?, ?),
+			 "IPA DLCX ACK");
+}
+testcase TC_ipa_crcx_mdcx_mdcx_dlcx_not_active() runs on test_CT {
+	var ConnHdlrPars pars := valueof(t_Pars(t_RslChanNr_Bm(1), ts_RSL_ChanMode_SIGN));
+	f_init(testcasename());
+	var ConnHdlr vc_conn := f_start_handler(refers(f_TC_ipa_crcx_mdcx_mdcx_dlcx_not_active), pars);
+	vc_conn.done;
+}
+
 /* IPA CRCX on SDCCH/4 and SDCCH/8 (doesn't make sense) */
 function f_TC_ipa_crcx_sdcch_not_active(charstring id) runs on ConnHdlr {
 	f_rsl_transceive(ts_RSL_IPA_CRCX(g_chan_nr), tr_RSL_IPA_CRCX_NACK(g_chan_nr, ?),
@@ -1122,6 +1149,7 @@
 	execute( TC_ipa_dlcx_not_active() );
 	execute( TC_ipa_crcx_twice_not_active() );
 	execute( TC_ipa_crcx_mdcx_dlcx_not_active() );
+	execute( TC_ipa_crcx_mdcx_mdcx_dlcx_not_active() );
 	execute( TC_ipa_crcx_sdcch_not_active() );
 }
 

-- 
To view, visit https://gerrit.osmocom.org/6901
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I58475e15958002e18cbe9d471bb5c8959bbf7bed
Gerrit-PatchSet: 1
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Owner: Harald Welte <laforge at gnumonks.org>



More information about the gerrit-log mailing list