Change in osmo-ttcn3-hacks[master]: fr: Make TC_foo() actually terminate

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

laforge gerrit-no-reply at lists.osmocom.org
Wed Feb 3 19:00:44 UTC 2021


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

Change subject: fr: Make TC_foo() actually terminate
......................................................................

fr: Make TC_foo() actually terminate

Rather than running in an endless loop (useful for manual tets),
terminate each UE_CT after sending 50 packets.  Also adjust the ramping
and timeouts in a way that it manages to terminate ahead of the guard
timeout.

Change-Id: I7f40f5c59d399d528072986d067b5014fbd085c4
---
M fr/FR_Tests.ttcn
1 file changed, 7 insertions(+), 3 deletions(-)

Approvals:
  Jenkins Builder: Verified
  laforge: Looks good to me, approved



diff --git a/fr/FR_Tests.ttcn b/fr/FR_Tests.ttcn
index 5777856..23c8e26 100644
--- a/fr/FR_Tests.ttcn
+++ b/fr/FR_Tests.ttcn
@@ -122,7 +122,7 @@
 	}
 
 	log ("Entering main loop");
-	while (true) {
+	for (var integer num_pkts := 0; num_pkts < 50; num_pkts := num_pkts + 1) {
 		var integer ran_index := 0;
 		//BSSGP[ran_index].send(ts_BSSGP_UL_UD(g_pars.tlli, g_pars.bssgp_cell_id[ran_index], llc_enc));
 		BSSGP[ran_index].send(ts_LLC_UI(f_rnd_octstring(512), '0000'B, '1'B, 0))
@@ -130,7 +130,7 @@
 	}
 }
 
-function f_start_ue(void_fn fn, charstring id, GbInstance gb, integer imsi_suffix, BSSGP_BVC_CT bvc_comp, float t_guard := 30.0)
+function f_start_ue(void_fn fn, charstring id, GbInstance gb, integer imsi_suffix, BSSGP_BVC_CT bvc_comp, float t_guard := 40.0)
 runs on test_CT return UE_CT
 {
 	var UE_CT ue_comp;
@@ -176,7 +176,11 @@
 				ue := f_start_ue(refers(f_ul_ud), id, g_gb[i], i*10000+j*100+k, bvc_comp);
 				ues := ues & { ue };
 				/* a bit of staggering to ensure the timers above don't run all at the same time */
-				f_sleep(0.05);
+				f_sleep(0.005);
+				/* FIXME: as the BSSGP emulation is already running, we must not
+				 * take too long to start the UE components.  If we do, the
+				 * BVC_S_UNBLOCKED notification will arrive before the components
+				 * all are running, meaning we never get that one :( */
 			}
 		}
 	}

-- 
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/22661
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: I7f40f5c59d399d528072986d067b5014fbd085c4
Gerrit-Change-Number: 22661
Gerrit-PatchSet: 2
Gerrit-Owner: laforge <laforge at osmocom.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge at osmocom.org>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210203/f010a240/attachment.htm>


More information about the gerrit-log mailing list