Change in osmo-ttcn3-hacks[master]: BTS_Tests: accept templates as parameters in t_EITC()

fixeria gerrit-no-reply at lists.osmocom.org
Tue Jun 1 14:34:38 UTC 2021


fixeria has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/24478 )

Change subject: BTS_Tests: accept templates as parameters in t_EITC()
......................................................................

BTS_Tests: accept templates as parameters in t_EITC()

Change-Id: I56cd32a6ba91c078608d64c95538b9a43e2fada9
Related: SYS#4895, OS#4941
---
M bts/BTS_Tests.ttcn
1 file changed, 26 insertions(+), 25 deletions(-)

Approvals:
  Jenkins Builder: Verified
  pespin: Looks good to me, but someone else must approve
  laforge: Looks good to me, approved



diff --git a/bts/BTS_Tests.ttcn b/bts/BTS_Tests.ttcn
index 6c5663a..d00c40e 100644
--- a/bts/BTS_Tests.ttcn
+++ b/bts/BTS_Tests.ttcn
@@ -6216,7 +6216,8 @@
 	boolean		exp
 }
 friend type record of RllTestCase RllTestCases;
-friend template RllTestCase t_EITC(uint3_t sapi, RslLinkId id,
+friend template RllTestCase t_EITC(template (present) uint3_t sapi,
+				   template (present) RslLinkId id,
 				   octetstring l3, boolean exp) := {
 	sapi := sapi,
 	link_id := id,
@@ -6293,16 +6294,16 @@
 testcase TC_rll_est_ind() runs on test_CT {
 	var RllTestCases tcs := {
 		/* SAPI0 establishment (contention resolution) */
-		valueof(t_EITC(0, valueof(ts_RslLinkID_DCCH(0)), '01020304'O, true)),
+		valueof(t_EITC(0, ts_RslLinkID_DCCH(0), '01020304'O, true)),
 		/* normal SAPI0 establishment */
-		valueof(t_EITC(0, valueof(ts_RslLinkID_DCCH(0)), ''O, true)),
+		valueof(t_EITC(0, ts_RslLinkID_DCCH(0), ''O, true)),
 		/* SAPI 3 doesn't support contention resolution */
-		valueof(t_EITC(3, valueof(ts_RslLinkID_DCCH(3)), '01020304'O, false)),
-		valueof(t_EITC(3, valueof(ts_RslLinkID_SACCH(3)), '01020304'O, false)),
+		valueof(t_EITC(3, ts_RslLinkID_DCCH(3), '01020304'O, false)),
+		valueof(t_EITC(3, ts_RslLinkID_SACCH(3), '01020304'O, false)),
 		/* normal SAPI3 establishment on main DCCH */
-		valueof(t_EITC(3, valueof(ts_RslLinkID_DCCH(3)), ''O, true)),
+		valueof(t_EITC(3, ts_RslLinkID_DCCH(3), ''O, true)),
 		/* normal SAPI3 establishment on SACCH */
-		valueof(t_EITC(3, valueof(ts_RslLinkID_SACCH(3)), ''O, true))
+		valueof(t_EITC(3, ts_RslLinkID_SACCH(3), ''O, true))
 	};
 	f_rll_testmatrix(tcs, refers(f_TC_rll_est_ind));
 }
@@ -6337,14 +6338,14 @@
 testcase TC_rll_est_req_DCCH_3() runs on test_CT {
 	var RllTestCases tcs := {
 		/* normal SAPI3 establishment on main DCCH */
-		valueof(t_EITC(3, valueof(ts_RslLinkID_DCCH(3)), ''O, true))//,
+		valueof(t_EITC(3, ts_RslLinkID_DCCH(3), ''O, true))//,
 	};
 	f_rll_testmatrix(tcs, refers(f_TC_rll_est_req));
 }
 testcase TC_rll_est_req_ACCH_3() runs on test_CT {
 	var RllTestCases tcs := {
 		/* normal SAPI3 establishment on SACCH */
-		valueof(t_EITC(3, valueof(ts_RslLinkID_SACCH(3)), ''O, true))
+		valueof(t_EITC(3, ts_RslLinkID_SACCH(3), ''O, true))
 	}
 	f_rll_testmatrix(tcs, refers(f_TC_rll_est_req));
 }
@@ -6435,26 +6436,26 @@
 }
 testcase TC_rll_rel_ind_DCCH_0() runs on test_CT {
 	var RllTestCases tcs := {
-		valueof(t_EITC(0, valueof(ts_RslLinkID_DCCH(0)), '01020304'O, true))
+		valueof(t_EITC(0, ts_RslLinkID_DCCH(0), '01020304'O, true))
 	};
 	f_rll_testmatrix(tcs, refers(f_TC_rll_rel_ind));
 }
 
 testcase TC_rll_rel_ind_ACCH_0() runs on test_CT {
 	var RllTestCases tcs := {
-		valueof(t_EITC(0, valueof(ts_RslLinkID_SACCH(0)), ''O, true))
+		valueof(t_EITC(0, ts_RslLinkID_SACCH(0), ''O, true))
 	};
 	f_rll_testmatrix(tcs, refers(f_TC_rll_rel_ind));
 }
 testcase TC_rll_rel_ind_DCCH_3() runs on test_CT {
 	var RllTestCases tcs := {
-		valueof(t_EITC(3, valueof(ts_RslLinkID_DCCH(3)), ''O, true))
+		valueof(t_EITC(3, ts_RslLinkID_DCCH(3), ''O, true))
 	};
 	f_rll_testmatrix(tcs, refers(f_TC_rll_rel_ind));
 }
 testcase TC_rll_rel_ind_ACCH_3() runs on test_CT {
 	var RllTestCases tcs := {
-		valueof(t_EITC(3, valueof(ts_RslLinkID_SACCH(3)), ''O, true))
+		valueof(t_EITC(3, ts_RslLinkID_SACCH(3), ''O, true))
 	};
 	f_rll_testmatrix(tcs, refers(f_TC_rll_rel_ind));
 }
@@ -6488,10 +6489,10 @@
 }
 testcase TC_rll_rel_req() runs on test_CT {
 	var RllTestCases tcs := {
-		valueof(t_EITC(0, valueof(ts_RslLinkID_DCCH(0)), '01020304'O, true)),
-		valueof(t_EITC(0, valueof(ts_RslLinkID_SACCH(0)), ''O, true)),
-		valueof(t_EITC(3, valueof(ts_RslLinkID_DCCH(3)), ''O, true)),
-		valueof(t_EITC(3, valueof(ts_RslLinkID_SACCH(3)), ''O, true))
+		valueof(t_EITC(0, ts_RslLinkID_DCCH(0), '01020304'O, true)),
+		valueof(t_EITC(0, ts_RslLinkID_SACCH(0), ''O, true)),
+		valueof(t_EITC(3, ts_RslLinkID_DCCH(3), ''O, true)),
+		valueof(t_EITC(3, ts_RslLinkID_SACCH(3), ''O, true))
 	};
 	f_rll_testmatrix(tcs, refers(f_TC_rll_rel_req));
 }
@@ -6531,16 +6532,16 @@
 testcase TC_rll_unit_data_req_DCCH() runs on test_CT {
 	var octetstring l3 := f_rnd_octstring(15);
 	var RllTestCases tcs := {
-		valueof(t_EITC(0, valueof(ts_RslLinkID_DCCH(0)), l3, true)),
-		valueof(t_EITC(3, valueof(ts_RslLinkID_DCCH(3)), l3, true))
+		valueof(t_EITC(0, ts_RslLinkID_DCCH(0), l3, true)),
+		valueof(t_EITC(3, ts_RslLinkID_DCCH(3), l3, true))
 	};
 	f_rll_testmatrix(tcs, refers(f_TC_rll_ud_req));
 }
 testcase TC_rll_unit_data_req_ACCH() runs on test_CT {
 	var octetstring l3 := f_rnd_octstring(19);
 	var RllTestCases tcs := {
-		valueof(t_EITC(0, valueof(ts_RslLinkID_SACCH(0)), l3, true)),
-		valueof(t_EITC(3, valueof(ts_RslLinkID_SACCH(3)), l3, true))
+		valueof(t_EITC(0, ts_RslLinkID_SACCH(0), l3, true)),
+		valueof(t_EITC(3, ts_RslLinkID_SACCH(3), l3, true))
 	};
 	f_rll_testmatrix(tcs, refers(f_TC_rll_ud_req));
 }
@@ -6573,16 +6574,16 @@
 testcase TC_rll_unit_data_ind_DCCH() runs on test_CT {
 	var octetstring l3 := f_rnd_octstring(20);
 	var RllTestCases tcs := {
-		valueof(t_EITC(0, valueof(ts_RslLinkID_DCCH(0)), l3, true)),
-		valueof(t_EITC(3, valueof(ts_RslLinkID_DCCH(3)), l3, true))
+		valueof(t_EITC(0, ts_RslLinkID_DCCH(0), l3, true)),
+		valueof(t_EITC(3, ts_RslLinkID_DCCH(3), l3, true))
 	};
 	f_rll_testmatrix(tcs, refers(f_TC_rll_ud_ind));
 }
 testcase TC_rll_unit_data_ind_ACCH() runs on test_CT {
 	var octetstring l3 := f_rnd_octstring(18);
 	var RllTestCases tcs := {
-		valueof(t_EITC(0, valueof(ts_RslLinkID_SACCH(0)), l3, true)),
-		valueof(t_EITC(3, valueof(ts_RslLinkID_SACCH(3)), l3, true))
+		valueof(t_EITC(0, ts_RslLinkID_SACCH(0), l3, true)),
+		valueof(t_EITC(3, ts_RslLinkID_SACCH(3), l3, true))
 	};
 	f_rll_testmatrix(tcs, refers(f_TC_rll_ud_ind));
 }

-- 
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/24478
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I56cd32a6ba91c078608d64c95538b9a43e2fada9
Gerrit-Change-Number: 24478
Gerrit-PatchSet: 1
Gerrit-Owner: fixeria <vyanitskiy at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy at sysmocom.de>
Gerrit-Reviewer: laforge <laforge at osmocom.org>
Gerrit-Reviewer: pespin <pespin at sysmocom.de>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210601/4340c8e8/attachment.htm>


More information about the gerrit-log mailing list