aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPau Espin Pedrol <pespin@sysmocom.de>2019-06-10 16:54:42 +0200
committerpespin <pespin@sysmocom.de>2019-06-13 14:33:23 +0000
commitbdcfe03ed4bd95d84738dfb9168ada8e9862771e (patch)
treeba5ca8d1ad04788e088fd586ab7e756b16bfd0df
parent579cd7a4065f4fbe9079e1b7aca4b84a7f556d32 (diff)
bscnat: Move generic code to wait for test into its own function
-rw-r--r--bsc-nat/BSCNAT_Tests.ttcn15
1 files changed, 10 insertions, 5 deletions
diff --git a/bsc-nat/BSCNAT_Tests.ttcn b/bsc-nat/BSCNAT_Tests.ttcn
index 2fab4a37..6b0c757a 100644
--- a/bsc-nat/BSCNAT_Tests.ttcn
+++ b/bsc-nat/BSCNAT_Tests.ttcn
@@ -163,12 +163,8 @@ function f_init(boolean use_osmux) runs on test_CT {
}
-function f_TC_recv_dump(boolean use_osmux := false) runs on test_CT {
+function f_wait_finish(timer T) runs on test_CT {
var integer i;
- timer T := 30.0;
-
- f_init(use_osmux);
-
alt {
/* wait for BSC to stop. The idea is that the BSC components terminate first */
[] bsc[0].BSC.done { }
@@ -182,6 +178,15 @@ function f_TC_recv_dump(boolean use_osmux := false) runs on test_CT {
}
}
+
+function f_TC_recv_dump(boolean use_osmux := false) runs on test_CT {
+ timer T := 30.0;
+
+ f_init(use_osmux);
+
+ f_wait_finish(T);
+}
+
testcase TC_recv_dump() runs on test_CT {
f_TC_recv_dump();
}