diff --git a/sysmocom/ttcn3/suites/ttcn3_bts_tests/lib/testlib.py b/sysmocom/ttcn3/suites/ttcn3_bts_tests/lib/testlib.py index 35483338..c3b3f350 100644 --- a/sysmocom/ttcn3/suites/ttcn3_bts_tests/lib/testlib.py +++ b/sysmocom/ttcn3/suites/ttcn3_bts_tests/lib/testlib.py @@ -4,7 +4,9 @@ from mako.template import Template from osmo_gsm_tester.testenv import * -def run_ttcn3(tenv, testdir, bts, osmocon, nat_rsl_ip, ttcn3_test_execute, ttcn3_test_extra_module_params=""): +def run_ttcn3(tenv, testdir, bts, osmocon, nat_rsl_ip, + ttcn3_test_groups = [], + ttcn3_test_extra_module_params=""): own_dir = testdir script_file = os.path.join(testdir, 'scripts', 'run_ttcn3_docker.sh') bts_tmpl_file = os.path.join(testdir, 'scripts', 'BTS_Tests.cfg.tmpl') @@ -23,7 +25,7 @@ def run_ttcn3(tenv, testdir, bts, osmocon, nat_rsl_ip, ttcn3_test_execute, ttcn3 mytemplate = Template(filename=bts_tmpl_file) r = mytemplate.render(btsvty_ctrl_hostname=bts.remote_addr(), pcu_available=pcu_available, - ttcn3_test_execute=ttcn3_test_execute, + ttcn3_test_groups=ttcn3_test_groups, ttcn3_test_extra_module_params=ttcn3_test_extra_module_params) with open(bts_cfg_file, 'w') as f: f.write(r) diff --git a/sysmocom/ttcn3/suites/ttcn3_bts_tests/scripts/BTS_Tests.cfg.tmpl b/sysmocom/ttcn3/suites/ttcn3_bts_tests/scripts/BTS_Tests.cfg.tmpl index 510234e5..4756ea1e 100644 --- a/sysmocom/ttcn3/suites/ttcn3_bts_tests/scripts/BTS_Tests.cfg.tmpl +++ b/sysmocom/ttcn3/suites/ttcn3_bts_tests/scripts/BTS_Tests.cfg.tmpl @@ -29,4 +29,6 @@ ${ttcn3_test_extra_module_params} [MAIN_CONTROLLER] [EXECUTE] -${ttcn3_test_execute} +% for group in ttcn3_test_groups: +${group}.control +% endfor diff --git a/sysmocom/ttcn3/suites/ttcn3_bts_tests/ttcn3_bts_tests.py b/sysmocom/ttcn3/suites/ttcn3_bts_tests/ttcn3_bts_tests.py index 43824544..7f0b24f7 100755 --- a/sysmocom/ttcn3/suites/ttcn3_bts_tests/ttcn3_bts_tests.py +++ b/sysmocom/ttcn3/suites/ttcn3_bts_tests/ttcn3_bts_tests.py @@ -6,7 +6,9 @@ import testlib tenv.test_import_modules_register_for_cleanup(testlib) from testlib import run_ttcn3 -ttcn3_test_execute="BTS_Tests.control" +ttcn3_test_groups = [ + 'BTS_Tests', +] hlr_dummy = tenv.hlr() mgw_dummy = tenv.mgw() @@ -46,4 +48,4 @@ print('Starting osmocon') osmocon.start() testdir = os.path.dirname(os.path.realpath(__file__)) -run_ttcn3(tenv, testdir, bts, osmocon, nat_rsl_ip, ttcn3_test_execute) +run_ttcn3(tenv, testdir, bts, osmocon, nat_rsl_ip, ttcn3_test_groups)