daniel has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/42135?usp=email )
Change subject: Fix/change TC_tcap_loadshare_ipa_tcap_udts() ......................................................................
Fix/change TC_tcap_loadshare_ipa_tcap_udts()
The behaviour changed to not reject tcap messages outside of any valid route. Change the test expectation that these messages are indeed forwarded.
Change-Id: Ibffa98702fd6eb276410630ab525d986fa0f36e0 --- M stp/STP_Tests_TCAP.ttcn M stp/expected-results.xml 2 files changed, 24 insertions(+), 14 deletions(-)
Approvals: fixeria: Looks good to me, but someone else must approve Jenkins Builder: Verified daniel: Looks good to me, approved
diff --git a/stp/STP_Tests_TCAP.ttcn b/stp/STP_Tests_TCAP.ttcn index fe29950..ebacbc1 100644 --- a/stp/STP_Tests_TCAP.ttcn +++ b/stp/STP_Tests_TCAP.ttcn @@ -636,12 +636,12 @@ setverdict(pass); }
-/* Test if UDTS is sent back when sending a TCAP messages with a OTID not valid +/* Test if TCAP message is routed with an OTID not in any tcap range * * node a: 0..99 * node b: 100..199 */ -testcase TC_tcap_loadshare_ipa_tcap_udts() runs on TCAP_CT { +testcase TC_tcap_loadshare_ipa_tcap_norange() runs on TCAP_CT { var template (value) IPA_EXT_TCAP_ROUTING_Message tcap_rt_msg; var Misc_Helpers.ro_charstring tcap_asps := { "asp-m3ua-loadshare-0-0", "asp-m3ua-loadshare-0-1", @@ -649,35 +649,45 @@ "asp-ipa-loadshare-0-1" }; var TCAP_CT_Configurations tcap_configs := tcap_build_configs(tcap_asps); var template (value) TCMessage tcap_msg; + var OCT4 otid := int2oct(250, 4); timer T := 5.0; + var integer rx_asp;
f_init_tcap(tcap_configs); /* Configure TCAP routing on IPA ASPs "asp-ipa-loadshare-0-0/1" */ f_tcap_loadshare_register(2, 0, 99, 3, 100, 199);
- /* send a TCAP message with oTID 250 (no range available) */ - /* TCAP Being: O -> T */ - tcap_msg := ts_TCAP_Begin(int2oct(250, 4)); + tcap_msg := ts_TCAP_Begin(otid); f_asp_tx_tcap(tcap_msg, 0);
- var template (present) TCAP_N_NOTICE_ind exp_sccp_notice_ind := - tr_TCAP_N_NOTICE_ind(g_tcap[0].sccp_addr_own, - g_tcap[0].sccp_addr_peer, - *, + /* Get the asp_idx of the received message to verify related + * messages are routed to the same ASP */ + var template (present) TCAP_N_UNITDATA_ind exp_sccp_unitdata_ind := + tr_TCAP_UNITDATA_ind(g_tcap[0].sccp_addr_peer, + g_tcap[0].sccp_addr_own, tcap_msg); + T.start; alt { - [] any from SCCP_TCAP.receive(exp_sccp_notice_ind) { - setverdict(pass); + [] SCCP_TCAP[2].receive(exp_sccp_unitdata_ind) { + rx_asp := 2; + } + [] SCCP_TCAP[3].receive(exp_sccp_unitdata_ind) { + rx_asp := 3; } [] T.timeout { - setverdict(fail, __SCOPE__, "(): Timeout waiting for UDTS"); + setverdict(fail, __SCOPE__, "(): Timeout waiting for TCAP message"); Misc_Helpers.f_shutdown(__BFILE__, __LINE__); } }
+ /* The next message should be routed to the same ASP */ + tcap_msg := ts_TCAP_Continue(otid, int2oct(1234, 4)); + f_asp_tx_tcap(tcap_msg, 0); + f_asp_tx_tcap_exp(tcap_msg, 0, rx_asp); + setverdict(pass); }
@@ -700,7 +710,7 @@ execute( TC_tcap_loadshare_ipa_tcap_range_success_pc_ssn() ); execute( TC_tcap_loadshare_ipa_tcap_range_success_pc_ssn2() ); execute( TC_tcap_loadshare_ipa_tcap_range_fail_pc_ssn_overlap() ); - execute( TC_tcap_loadshare_ipa_tcap_udts() ); + execute( TC_tcap_loadshare_ipa_tcap_norange() ); }
diff --git a/stp/expected-results.xml b/stp/expected-results.xml index 5834abb..7d9d684 100644 --- a/stp/expected-results.xml +++ b/stp/expected-results.xml @@ -83,5 +83,5 @@ <testcase classname='STP_Tests_TCAP' name='TC_tcap_loadshare_ipa_tcap_range_success_pc_ssn' time='MASKED'/> <testcase classname='STP_Tests_TCAP' name='TC_tcap_loadshare_ipa_tcap_range_success_pc_ssn2' time='MASKED'/> <testcase classname='STP_Tests_TCAP' name='TC_tcap_loadshare_ipa_tcap_range_fail_pc_ssn_overlap' time='MASKED'/> - <testcase classname='STP_Tests_TCAP' name='TC_tcap_loadshare_ipa_tcap_udts' time='MASKED'/> + <testcase classname='STP_Tests_TCAP' name='TC_tcap_loadshare_ipa_tcap_norange' time='MASKED'/> </testsuite>