bsc-cbsp: Test BTS Failure+Restart when BTS becomes (un)available
Related: SYS#5910 Change-Id: I35ddde7bc2e39d35c301f1153416b549ba1630cd
This commit is contained in:
parent
f2c701df80
commit
2b33d4e2d3
|
@ -40,6 +40,10 @@ import from CBSP_CodecPort all;
|
||||||
import from Osmocom_VTY_Functions all;
|
import from Osmocom_VTY_Functions all;
|
||||||
import from TELNETasp_PortType all;
|
import from TELNETasp_PortType all;
|
||||||
|
|
||||||
|
import from Osmocom_CTRL_Functions all;
|
||||||
|
import from Osmocom_CTRL_Types all;
|
||||||
|
import from Osmocom_CTRL_Adapter all;
|
||||||
|
|
||||||
modulepar {
|
modulepar {
|
||||||
charstring mp_cbc_ip := "127.0.0.1";
|
charstring mp_cbc_ip := "127.0.0.1";
|
||||||
charstring mp_cbc_ip6 := "::1";
|
charstring mp_cbc_ip6 := "::1";
|
||||||
|
@ -47,6 +51,8 @@ modulepar {
|
||||||
charstring mp_bsc_cbsp_ip := "127.0.0.1";
|
charstring mp_bsc_cbsp_ip := "127.0.0.1";
|
||||||
charstring mp_bsc_cbsp_ip6 := "::1";
|
charstring mp_bsc_cbsp_ip6 := "::1";
|
||||||
integer mp_bsc_cbsp_port := 48050;
|
integer mp_bsc_cbsp_port := 48050;
|
||||||
|
/* port number to which to establish the IPA CTRL connection */
|
||||||
|
integer mp_bsc_ctrl_port := 4249;
|
||||||
|
|
||||||
/* BTS 0: 001-01-1-0 with CBCH
|
/* BTS 0: 001-01-1-0 with CBCH
|
||||||
* BTS 1: 001-01-1-1 with CBCH
|
* BTS 1: 001-01-1-1 with CBCH
|
||||||
|
@ -536,6 +542,75 @@ testcase TC_cbsp_reset_bss() runs on cbsp_test_CT {
|
||||||
setverdict(pass);
|
setverdict(pass);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Test if a LAC_CI FAILURE Ind is sent when TRX holding the CBCH is locked
|
||||||
|
* (becomes unavailable). LAC_CI RESTART Ind should be sent when the TRX becomes
|
||||||
|
* unlocked again. */
|
||||||
|
testcase TC_cbsp_cell_rflock_failure_restart() runs on cbsp_test_CT {
|
||||||
|
var template CBSP_PDU rx;
|
||||||
|
|
||||||
|
g_pars := valueof(ts_CBSP_Pars_default(false, 0, 0));
|
||||||
|
f_init();
|
||||||
|
|
||||||
|
/* Lock the TRX, CBCH should become unavailable and BSC send FAILURE */
|
||||||
|
f_ctrl_set(IPA_CTRL, "bts.0.trx.0.rf_locked", "1");
|
||||||
|
|
||||||
|
rx := tr_CBSP_FAILURE({CBSP_FailureListItem_LAC_CI(bssmap_lac_ci(mp_cgi_bts0),
|
||||||
|
CBSP_CAUSE_CB_NOT_OPERATIONAL)},
|
||||||
|
CBSP_BC_MSGT_CBS);
|
||||||
|
alt {
|
||||||
|
[] CBSP[0].receive(tr_CBSP_Recv(g_cbsp_conn_id[0], rx)) {
|
||||||
|
setverdict(pass);
|
||||||
|
}
|
||||||
|
[] CBSP[0].receive(tr_CBSP_Recv(g_cbsp_conn_id[0], ?)) {
|
||||||
|
setverdict(fail, "Received unexpected CBSP");
|
||||||
|
mtc.stop;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Unlock the TRX, CBCH should become available and BSC send RESTART */
|
||||||
|
f_ctrl_set(IPA_CTRL, "bts.0.trx.0.rf_locked", "0");
|
||||||
|
rx := tr_CBSP_RESTART(ts_BSSMAP_CIL_LAC_CI({bssmap_lac_ci(mp_cgi_bts0)}),
|
||||||
|
CBSP_BC_MSGT_CBS, ?);
|
||||||
|
alt {
|
||||||
|
[] CBSP[0].receive(tr_CBSP_Recv(g_cbsp_conn_id[0], rx)) {
|
||||||
|
setverdict(pass);
|
||||||
|
}
|
||||||
|
[] CBSP[0].receive(tr_CBSP_Recv(g_cbsp_conn_id[0], ?)) {
|
||||||
|
setverdict(fail, "Received unexpected CBSP");
|
||||||
|
mtc.stop;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
setverdict(pass);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Test if a LAC_CI FAILURE Ind is sent when conn of TRX holding the CBCH goes down. */
|
||||||
|
testcase TC_cbsp_cell_rsl_down_failure() runs on cbsp_test_CT {
|
||||||
|
var template CBSP_PDU rx;
|
||||||
|
|
||||||
|
g_pars := valueof(ts_CBSP_Pars_default(false, 0, 0));
|
||||||
|
f_init();
|
||||||
|
|
||||||
|
/* Drop RSL link of the TRX holding the CBCH: */
|
||||||
|
f_ipa_rsl_stop(bts[0][0].rsl);
|
||||||
|
|
||||||
|
rx := tr_CBSP_FAILURE({CBSP_FailureListItem_LAC_CI(bssmap_lac_ci(mp_cgi_bts0),
|
||||||
|
CBSP_CAUSE_CB_NOT_OPERATIONAL)},
|
||||||
|
CBSP_BC_MSGT_CBS);
|
||||||
|
alt {
|
||||||
|
[] CBSP[0].receive(tr_CBSP_Recv(g_cbsp_conn_id[0], rx)) {
|
||||||
|
setverdict(pass);
|
||||||
|
}
|
||||||
|
[] CBSP[0].receive(tr_CBSP_Recv(g_cbsp_conn_id[0], ?)) {
|
||||||
|
setverdict(fail, "Received unexpected CBSP");
|
||||||
|
mtc.stop;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* TODO: call f_init() again to reconnect? */
|
||||||
|
setverdict(pass);
|
||||||
|
}
|
||||||
|
|
||||||
testcase TC_cbsp_write() runs on cbsp_test_CT {
|
testcase TC_cbsp_write() runs on cbsp_test_CT {
|
||||||
var template (value) CBSP_PDU tx;
|
var template (value) CBSP_PDU tx;
|
||||||
var CBSP_IEs pages := {f_gen_page()};
|
var CBSP_IEs pages := {f_gen_page()};
|
||||||
|
@ -1081,6 +1156,8 @@ control {
|
||||||
execute( TC_cbsp_bsc_client() );
|
execute( TC_cbsp_bsc_client() );
|
||||||
execute( TC_cbsp_bsc_client_ipv6() );
|
execute( TC_cbsp_bsc_client_ipv6() );
|
||||||
execute( TC_cbsp_reset_bss() );
|
execute( TC_cbsp_reset_bss() );
|
||||||
|
execute( TC_cbsp_cell_rflock_failure_restart() );
|
||||||
|
execute( TC_cbsp_cell_rsl_down_failure() );
|
||||||
|
|
||||||
/* test various different types of Cell Identities */
|
/* test various different types of Cell Identities */
|
||||||
execute( TC_cbsp_write_bss() );
|
execute( TC_cbsp_write_bss() );
|
||||||
|
|
|
@ -134,6 +134,18 @@ template CBSP_IE tr_CbspFailList(template CBSP_FailureListItems items := ?) :=
|
||||||
list := items
|
list := items
|
||||||
}});
|
}});
|
||||||
|
|
||||||
|
template (present) CBSP_FailureListItem CBSP_FailureListItem_LAC_CI(
|
||||||
|
template (present) BSSMAP_FIELD_CellIdentification_LAC_CI lac_ci := ?,
|
||||||
|
template (present) CBSP_Cause cause := ?) :=
|
||||||
|
{
|
||||||
|
spare1_4 := '0000'B,
|
||||||
|
cell_id_discr := '0001'B,
|
||||||
|
cell_id := {
|
||||||
|
cI_LAC_CI := lac_ci
|
||||||
|
},
|
||||||
|
cause := cause
|
||||||
|
};
|
||||||
|
|
||||||
template (value) CBSP_IE ts_CbspNumComplList(template (value) CBSP_IE_NumBcastComplList list) :=
|
template (value) CBSP_IE ts_CbspNumComplList(template (value) CBSP_IE_NumBcastComplList list) :=
|
||||||
ts_CBSP_IE(CBSP_IEI_NUM_BCAST_COMPL_LIST, {num_bcast_compl_list := list});
|
ts_CBSP_IE(CBSP_IEI_NUM_BCAST_COMPL_LIST, {num_bcast_compl_list := list});
|
||||||
template CBSP_IE tr_CbspNumComplList(template CBSP_IE_NumBcastComplList list := ?) :=
|
template CBSP_IE tr_CbspNumComplList(template CBSP_IE_NumBcastComplList list := ?) :=
|
||||||
|
|
Loading…
Reference in New Issue