BTS_Tests: make TC_pcu_interf_ind more stable

The first interference report may contain unreliable values, so we
ignore it and start the actual matching only after receiving it.

Change-Id: I44b0db6675ecf740fba7ad2a6882f86da018febf
Related: SYS#5313
changes/96/26196/3
Vadim Yanitskiy 1 year ago committed by fixeria
parent d9b60e60b9
commit 3b868cb1aa
  1. 22
      bts/BTS_Tests.ttcn

@ -6105,6 +6105,7 @@ testcase TC_pcu_interf_ind() runs on test_CT {
var template PCUIF_Message tr_interf_ind;
var template PCUIF_interf ts_interf;
var integer interf_ind_num := 0;
var boolean first := true;
var PCUIF_send_data sd;
timer T;
@ -6129,16 +6130,17 @@ testcase TC_pcu_interf_ind() runs on test_CT {
interf := ts_interf
);
/* 4 SACCH periods => 4 reports (plus some guard time) */
var float Tval := int2float(4 * 480) / 1000.0 + 0.5;
/* Let it some time to stabilize */
f_sleep(0.5);
PCU.clear;
T.start(Tval);
T.start(0.480 * 1.5);
alt {
[] PCU.receive(t_SD_PCUIF(g_pcu_conn_id, tr_interf_ind)) -> value sd {
/* The first interference report may contain unreliable values, so we ignore it */
[first] PCU.receive(t_SD_PCUIF(g_pcu_conn_id, tr_PCUIF_INTERF_IND(0, 0))) {
/* 4 SACCH periods => 4 reports (plus some guard time) */
T.start(0.480 * 4.0 + 0.480 / 2.0);
first := false;
repeat;
}
/* Subsequent interference reports shall match our expectations */
[not first] PCU.receive(t_SD_PCUIF(g_pcu_conn_id, tr_interf_ind)) -> value sd {
/* Check TDMA frame number period */
if (sd.data.u.interf_ind.fn mod 104 != 0) {
setverdict(fail, "Odd TDMA frame number := ",
@ -6148,7 +6150,7 @@ testcase TC_pcu_interf_ind() runs on test_CT {
if (interf_ind_num < 4)
{ repeat; }
}
[] PCU.receive(t_SD_PCUIF(g_pcu_conn_id, tr_PCUIF_INTERF_IND(0, 0))) -> value sd {
[not first] PCU.receive(t_SD_PCUIF(g_pcu_conn_id, tr_PCUIF_INTERF_IND(0, 0))) -> value sd {
setverdict(fail, "Received unexpected interference report: ", sd.data);
}
[] PCU.receive { repeat; }

Loading…
Cancel
Save