summaryrefslogtreecommitdiffstats
path: root/bsc
diff options
context:
space:
mode:
authorHarald Welte <laforge@gnumonks.org>2019-02-04 10:41:36 +0100
committerHarald Welte <laforge@gnumonks.org>2019-02-05 17:45:29 +0100
commit9978710c4bdbf6ddee087550c4cd5dc449f6003a (patch)
tree03aea4f2d6a145ae7434c6e21b167a4c8a09f236 /bsc
parent924b6ea17b870292589d3d23a875eae266d28e56 (diff)
bsc: Test CSFB "Fast Return" in new TC_chan_rel_hard_clear_csfb
When a MSC releases a connection using the BSSMAP CLEAR CMD, it can specify that this call was part of CSFB. The BSC is then supposed to add a special IE to the RR RELEASE message which will help the phone to switch back to LTE as soon as possible. This commit adds a new test case testing for exactly that behavior. The test does *not* verify if the EARFCN information contained is actually correct, only that the IE is present in the RR RELEASE. Change-Id: I7501fb25578412c882ff92da5d388f3079bbce7f Requires: osmo-bsc Ibfbb87e2e16b05032ad1cb91c11fad1b2f76d755 Related: OS#3777
Diffstat (limited to 'bsc')
-rw-r--r--bsc/BSC_Tests.ttcn33
1 files changed, 31 insertions, 2 deletions
diff --git a/bsc/BSC_Tests.ttcn b/bsc/BSC_Tests.ttcn
index 555aac8..5d8f375 100644
--- a/bsc/BSC_Tests.ttcn
+++ b/bsc/BSC_Tests.ttcn
@@ -856,7 +856,8 @@ function f_expect_chan_rel(integer bts_nr, RslChannelNr rsl_chan_nr,
boolean expect_deact_sacch := true,
boolean expect_rr_chan_rel := true,
boolean expect_rll_rel_req := true,
- boolean handle_rll_rel := true
+ boolean handle_rll_rel := true,
+ boolean is_csfb := false
) runs on test_CT {
var RslLinkId main_dcch := valueof(ts_RslLinkID_DCCH(0));
@@ -871,7 +872,11 @@ function f_expect_chan_rel(integer bts_nr, RslChannelNr rsl_chan_nr,
got_deact_sacch := true;
repeat;
}
- [] IPA_RSL[bts_nr].receive(tr_ASP_RSL_UD(IPAC_PROTO_RSL_TRX0, tr_RSL_DATA_REQ(rsl_chan_nr, ?, decmatch tr_RRM_RR_RELEASE))) {
+ [is_csfb] IPA_RSL[bts_nr].receive(tr_ASP_RSL_UD(IPAC_PROTO_RSL_TRX0, tr_RSL_DATA_REQ(rsl_chan_nr, ?, decmatch tr_RRM_RR_RELEASE_CSFB))) {
+ got_rr_chan_rel := true;
+ repeat;
+ }
+ [not is_csfb] IPA_RSL[bts_nr].receive(tr_ASP_RSL_UD(IPAC_PROTO_RSL_TRX0, tr_RSL_DATA_REQ(rsl_chan_nr, ?, decmatch tr_RRM_RR_RELEASE))) {
got_rr_chan_rel := true;
repeat;
}
@@ -932,6 +937,29 @@ testcase TC_chan_rel_hard_clear() runs on test_CT {
setverdict(pass);
}
+/* Test behavior of channel release after Clear Command with CSFB indicator from MSC */
+testcase TC_chan_rel_hard_clear_csfb() runs on test_CT {
+ var BSSAP_N_DATA_ind rx_di;
+ var DchanTuple dt;
+
+ f_init(1);
+
+ dt := f_est_dchan('23'O, 23, '00010203040506'O);
+
+ /* Instruct BSC to clear channel */
+ var BssmapCause cause := 0;
+ BSSAP.send(ts_BSSAP_DATA_req(dt.sccp_conn_id, ts_BSSMAP_ClearCommandCSFB(cause)));
+
+ /* expect Clear Complete from BSC on A */
+ BSSAP.receive(tr_BSSAP_DATA_ind(dt.sccp_conn_id, tr_BSSMAP_ClearComplete)) {
+ /* release the SCCP connection */
+ BSSAP.send(ts_BSSAP_DISC_req(dt.sccp_conn_id, 0));
+ }
+
+ f_expect_chan_rel(0, dt.rsl_chan_nr, expect_rll_rel_req := false, is_csfb := true);
+ setverdict(pass);
+}
+
/* Test behavior of channel release after hard RLSD from MSC */
testcase TC_chan_rel_hard_rlsd() runs on test_CT {
var DchanTuple dt;
@@ -3697,6 +3725,7 @@ control {
execute( TC_chan_rel_rll_rel_ind() );
execute( TC_chan_rel_conn_fail() );
execute( TC_chan_rel_hard_clear() );
+ execute( TC_chan_rel_hard_clear_csfb() );
execute( TC_chan_rel_hard_rlsd() );
execute( TC_chan_rel_hard_rlsd_ms_dead() );
execute( TC_chan_rel_a_reset() );