Add a TTCN3 module for IPA protocol testing

This new module allows us to test IPA code in libosmocore
and libosmo-netif. Currently only one test is implemented,
which sends a chopped IPA ping message and expects to receive
an IPA pong.

The system under test is any IPA speaker on any TCP port.
Any test suite may call parametrized functions to create
an IPA testing component and run a particular test.
So far, one such test has been added to the BSC_Tests suite.

Change-Id: I246a405414e36a44dc1e308692faab8bf04da0e6
Related: OS#2010
diff --git a/bsc/BSC_Tests.ttcn b/bsc/BSC_Tests.ttcn
index 4a34310..28ade1e 100644
--- a/bsc/BSC_Tests.ttcn
+++ b/bsc/BSC_Tests.ttcn
@@ -30,6 +30,7 @@
 import from IPA_Emulation all;
 import from IPA_CodecPort all;
 import from IPA_Types all;
+import from IPA_Testing all;
 import from RSL_Types all;
 import from RSL_Emulation all;
 import from MGCP_Emulation all;
@@ -2729,6 +2730,14 @@
 	setverdict(pass);
 }
 
+testcase TC_chopped_ipa_ping() runs on test_CT {
+	const Integers bsc_ipa_ports := {mp_bsc_rsl_port, mp_bsc_oml_port
+					 /* TOOD: This port is failing: mp_bsc_ctrl_port */ };
+	for (var integer i := 0; i < lengthof(bsc_ipa_ports); i := i + 1) {
+		IPA_Testing.f_run_TC_chopped_ipa_ping(mp_bsc_ip, bsc_ipa_ports[i], CONNECT_TO_SERVER);
+	}
+}
+
 /* Dyn PDCH todo:
    * activate OSMO as TCH/F
    * activate OSMO as TCH/H
@@ -2836,6 +2845,8 @@
 	execute( TC_dyn_pdch_osmo_act_deact() );
 	execute( TC_dyn_pdch_osmo_act_nack() );
 
+	execute( TC_chopped_ipa_ping() );
+
 	/* at bottom as they might crash OsmoBSC before OS#3182 is fixed */
 	execute( TC_early_conn_fail() );
 	execute( TC_late_conn_fail() );