Change in osmo-ttcn3-hacks[master]: msc: add as_optional_cc_rel to ignore CC REL during call abort tests

Neels Hofmeyr gerrit-no-reply at lists.osmocom.org
Thu Mar 7 15:39:06 UTC 2019


Neels Hofmeyr has uploaded this change for review. ( https://gerrit.osmocom.org/13167


Change subject: msc: add as_optional_cc_rel to ignore CC REL during call abort tests
......................................................................

msc: add as_optional_cc_rel to ignore CC REL during call abort tests

When aborting a call with a Clear Request, it is actually a good idea to
release an ongoing call with a CC Release message from the MSC. Allow this.

Change-Id: I8378f7602fecac8262b31b47ad9327a3782c1bcd
---
M msc/MSC_Tests.ttcn
1 file changed, 23 insertions(+), 9 deletions(-)



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

diff --git a/msc/MSC_Tests.ttcn b/msc/MSC_Tests.ttcn
index 7129f81..1edc7ad 100644
--- a/msc/MSC_Tests.ttcn
+++ b/msc/MSC_Tests.ttcn
@@ -152,6 +152,10 @@
 	}
 }
 
+private altstep as_optional_cc_rel(CallParameters cpars) runs on BSC_ConnHdlr {
+	[] BSSAP.receive(tr_PDU_DTAP_MT(tr_ML3_MT_CC_RELEASE(cpars.transaction_id))) { repeat; };
+}
+
 function f_init_smpp(charstring id) runs on MTC_CT {
 	id := id & "-SMPP";
 	var EsmePars pars := {
@@ -1267,7 +1271,13 @@
 
 	BSSAP.send(ts_PDU_DTAP_MO(ts_ML3_MO_CC_SETUP(cpars.transaction_id, cpars.called_party)));
 
+	var default ccrel := activate(as_optional_cc_rel(cpars));
+
 	f_expect_clear(185.0);
+
+	deactivate(ccrel);
+
+	f_sleep(1.0);
 }
 testcase TC_mo_setup_and_nothing() runs on MTC_CT {
 	var BSC_ConnHdlr vc_conn;
@@ -1477,7 +1487,6 @@
 		setverdict(fail, "Timeout waiting for channel release");
 		mtc.stop;
 		}
-	[] BSSAP.receive { repeat; }
 	[] MNCC.receive { repeat; }
 	[] GSUP.receive { repeat; }
 	[] MGCP.receive(tr_DLCX(?)) -> value mgcp_cmd {
@@ -1487,6 +1496,7 @@
 		}
 	[] MGCP.receive { repeat; }
 	[] as_clear_cmd_compl_disc();
+	[] as_optional_cc_rel(cpars);
 	}
 }
 testcase TC_mt_crcx_ran_reject() runs on MTC_CT {
@@ -1873,13 +1883,11 @@
 	/* Drop CRCX */
 	MGCP.receive(tr_CRCX) -> value mgcp_cmd;
 
-	/* Drop DTAP Release */
-	BSSAP.receive(tr_PDU_DTAP_MT(tr_ML3_MT_CC_RELEASE(cpars.transaction_id)));
-
-	/* Drop resent DTAP Release */
-	BSSAP.receive(tr_PDU_DTAP_MT(tr_ML3_MT_CC_RELEASE(cpars.transaction_id)));
+	var default ccrel := activate(as_optional_cc_rel(cpars));
 
 	f_expect_clear(60.0);
+
+	deactivate(ccrel);
 }
 testcase TC_mo_release_timeout() runs on MTC_CT {
 	var BSC_ConnHdlr vc_conn;
@@ -3154,10 +3162,16 @@
 	f_sleep(1.0);
 	BSSAP.send(ts_BSSMAP_ClearRequest(0));
 
-	MNCC.receive(tr_MNCC_REL_ind(?, ?)) -> value mncc;
+	var default ccrel := activate(as_optional_cc_rel(cpars));
 
-	BSSAP.receive(tr_BSSMAP_ClearCommand);
-	BSSAP.send(ts_BSSMAP_ClearComplete);
+	interleave {
+	[] MNCC.receive(tr_MNCC_REL_ind(?, ?)) { };
+	[] BSSAP.receive(tr_BSSMAP_ClearCommand) {
+			BSSAP.send(ts_BSSMAP_ClearComplete);
+		};
+	}
+
+	deactivate(ccrel);
 
 	f_sleep(1.0);
 }

-- 
To view, visit https://gerrit.osmocom.org/13167
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I8378f7602fecac8262b31b47ad9327a3782c1bcd
Gerrit-Change-Number: 13167
Gerrit-PatchSet: 1
Gerrit-Owner: Neels Hofmeyr <nhofmeyr at sysmocom.de>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20190307/51dfbca0/attachment-0001.html>


More information about the gerrit-log mailing list