[MERGED] osmo-ttcn3-hacks[master]: bts: enable CTRL interface tests

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
Wed Apr 4 08:04:51 UTC 2018


Harald Welte has submitted this change and it was merged.

Change subject: bts: enable CTRL interface tests
......................................................................


bts: enable CTRL interface tests

Start and stop the CTRL interface and provide CTRL bind interface config
modulepars.

Possibly everyones' local setups may need modification to allow the
ttcn3-bts-tests to reach osmo-bts-trx's CTRL port.

WARNING: This commit has to be merged "at the same time" as
I1ec86b157ebd46bf622a0ca51eba225f15c99fbb or the jenkins ttcn3-bts-tests will
fail.

a) if we want to set a modulepar mp_ctrl_ip here, it needs to be added to
osmo-ttcn3-hacks.

b) if we have the f_ipa_ctrl_start() in osmo-ttcn3-hacks, we need to configure
the proper IP and bind interface here, or all tests will fail because
f_ipa_ctrl_start() cannot connect.

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

Approvals:
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/bts/BTS_Tests.ttcn b/bts/BTS_Tests.ttcn
index b68e99b..4a4ced5 100644
--- a/bts/BTS_Tests.ttcn
+++ b/bts/BTS_Tests.ttcn
@@ -11,6 +11,7 @@
 import from L1CTL_Types all;
 import from LAPDm_Types all;
 import from Osmocom_CTRL_Adapter all;
+import from Osmocom_CTRL_Functions all;
 
 import from RSL_Types all;
 import from IPA_Types all;
@@ -50,6 +51,8 @@
 	charstring mp_pcu_socket := PCU_SOCK_DEFAULT;
 	integer mp_tolerance_rxqual := 1;
 	integer mp_tolerance_rxlev := 3;
+	charstring mp_ctrl_ip := "127.0.0.1";
+	integer mp_ctrl_port := 4238;
 }
 
 type record of RslChannelNr ChannelNrs;
@@ -285,6 +288,7 @@
 	RSL_CCHAN.receive(ASP_IPA_Event:{up_down := ASP_IPA_EVENT_UP});
 	f_sleep(0.5);	/* workaround for OS#3000 */
 	f_init_vty(id);
+	f_ipa_ctrl_start(mp_ctrl_ip, mp_ctrl_port);
 
 	/* Send SI3 to the BTS, it is needed for various computations */
 	f_rsl_bcch_fill(RSL_SYSTEM_INFO_3, ts_SI3_default);
@@ -306,6 +310,7 @@
 	/* shut down all "externally interfaced" components first to avoid unclean shutdown */
 	vc_IPA.stop;
 	vc_RSL.stop;
+	f_ipa_ctrl_stop();
 }
 
 /* Attach L1CTL to master test_CT (classic tests, non-handler mode) */

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I502b4891e6720ae2fb251c03542f707880a6f728
Gerrit-PatchSet: 2
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Owner: Neels Hofmeyr <nhofmeyr at sysmocom.de>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder



More information about the gerrit-log mailing list