bts: Add TC_pcu_data_req_pch() for testing PCU-originated PCH

Change-Id: I0f2c4f053ef1b8d61d565f94a548c47fe3666f16
Related: OS#4023
diff --git a/bts/BTS_Tests.ttcn b/bts/BTS_Tests.ttcn
index 2b22ac4..d9e989c 100644
--- a/bts/BTS_Tests.ttcn
+++ b/bts/BTS_Tests.ttcn
@@ -3470,6 +3470,29 @@
 	}
 }
 
+/* Send AGCH from PCU; check it appears on Um side */
+testcase TC_pcu_data_req_pch() runs on test_CT {
+	timer T := 3.0;
+	f_init_pcu_test();
+	f_init_l1ctl();
+	f_l1_tune(L1CTL);
+
+	f_TC_pcu_act_req(0, 0, 7, true);
+	/* three characters prefix: last 3 digits of IMSI as ASCII */
+	f_pcu_data_req(0, 0, 7, 0, 0, PCU_IF_SAPI_PCH, '313233'O & c_PCU_DATA);
+
+	T.start;
+	alt {
+	[] L1CTL.receive(tr_L1CTL_DATA_IND(t_RslChanNr_PCH_AGCH(0), ?, c_PCU_DATA)) {
+		setverdict(pass);
+		}
+	[] L1CTL.receive { repeat; }
+	[] T.timeout {
+		Misc_Helpers.f_shutdown(__BFILE__, __LINE__, fail, "Timeout waiting for PCU-originated PCH block on Um");
+		}
+	}
+}
+
 /* Send IMM.ASS from PCU for PCH; check it appears on Um side */
 testcase TC_pcu_data_req_imm_ass_pch() runs on test_CT {
 	var octetstring imm_ass := f_rnd_octstring(23);
@@ -5076,6 +5099,7 @@
 			execute( TC_pcu_data_req_ts_inactive() );
 		}
 		execute( TC_pcu_data_req_agch() );
+		execute( TC_pcu_data_req_pch() );
 		execute( TC_pcu_data_req_imm_ass_pch() );
 		execute( TC_pcu_rach_content() );
 		execute( TC_pcu_ext_rach_content() );