bsc: TC_ho_in_fail_ipa_crcx_timeout: new test

Verify that OsmoBSC runs into a timeout and aborts the handover if the
IPA CRCX is not answered by the BTS. This test ensures it still works
after removing a redundant timer, as discussed here:
https://gerrit.osmocom.org/c/osmo-bsc/+/30307/1#message-9e02be4de78c03ed25b8422d6eee4ba9c6dda9ff

Related: OS#5787
Change-Id: I2f79e3ff988a4315fbef3538f02403b818fa7839
diff --git a/bsc/BSC_Tests.ttcn b/bsc/BSC_Tests.ttcn
index 352a12e..9a2718a 100644
--- a/bsc/BSC_Tests.ttcn
+++ b/bsc/BSC_Tests.ttcn
@@ -7053,6 +7053,17 @@
 	f_shutdown_helper(ho := true);
 }
 
+testcase TC_ho_in_fail_ipa_crcx_timeout() runs on test_CT {
+	var TestHdlrParams pars := f_gen_test_hdlr_pars();
+
+	pars.ignore_ipa_media := true;
+	pars.expect_ho_fail_lchan_est := true;
+	pars.fail_on_dlcx := false;
+
+	f_tc_ho_into_this_bsc_main(pars);
+	f_shutdown_helper(ho := true);
+}
+
 /* An incoming inter-BSC HO can either issue the Handover Request message attached to the initial SCCP N-Connect (as in
  * the other tests we have so far), or the first CR can be "empty" with the BSSAP request following later. Test the
  * empty N-Connect case. */
@@ -12361,6 +12372,7 @@
 	execute( TC_ho_in_fail_no_detect() );
 	execute( TC_ho_in_fail_no_detect2() );
 	execute( TC_ho_in_fail_mgw_mdcx_timeout() );
+	execute( TC_ho_in_fail_ipa_crcx_timeout() );
 	execute( TC_ho_into_this_bsc_sccp_cr_without_bssap() );
 
 	execute( TC_ho_neighbor_config_1() );
diff --git a/bsc/MSC_ConnectionHandler.ttcn b/bsc/MSC_ConnectionHandler.ttcn
index aa54225..b3e6af6 100644
--- a/bsc/MSC_ConnectionHandler.ttcn
+++ b/bsc/MSC_ConnectionHandler.ttcn
@@ -508,7 +508,7 @@
 /* Altsteps for handling of media related commands. Can be activated by a given
  * test case if it expects to see media related handling (i.e. voice calls) */
 altstep as_Media() runs on MSC_ConnHdlr {
-	[] as_Media_ipacc();
+	[not g_pars.ignore_ipa_media] as_Media_ipacc();
 	[] as_Media_mgw();
 }
 
@@ -760,7 +760,8 @@
 	boolean		expect_ho_fail_lchan_est,
 	boolean		inter_bsc_ho_in__ho_req_in_initial_sccp_cr,
 	boolean		ignore_mgw_mdcx,
-	boolean		fail_on_dlcx
+	boolean		fail_on_dlcx,
+	boolean		ignore_ipa_media
 };
 
 /* Note: Do not use valueof() to get a value of this template, use
@@ -808,7 +809,8 @@
 	expect_ho_fail_lchan_est := false,
 	inter_bsc_ho_in__ho_req_in_initial_sccp_cr := true,
 	ignore_mgw_mdcx := false,
-	fail_on_dlcx := true
+	fail_on_dlcx := true,
+	ignore_ipa_media := false
 }
 
 function f_create_chan_and_exp(template (present) PDU_BSSAP exp_l3_compl := ?)