Change in osmo-ttcn3-hacks[master]: stp: Add tests for snm_inactive quirk

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

laforge gerrit-no-reply at lists.osmocom.org
Thu May 13 19:30:15 UTC 2021


laforge has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/24230 )


Change subject: stp: Add tests for snm_inactive quirk
......................................................................

stp: Add tests for snm_inactive quirk

Change-Id: Ic2a41e450a44794c8cf1c5a29871655f2cca4f6b
Related: OS#5148
---
M stp/STP_Tests_M3UA.ttcn
1 file changed, 48 insertions(+), 0 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/30/24230/1

diff --git a/stp/STP_Tests_M3UA.ttcn b/stp/STP_Tests_M3UA.ttcn
index 78819b4..dfa82a2 100644
--- a/stp/STP_Tests_M3UA.ttcn
+++ b/stp/STP_Tests_M3UA.ttcn
@@ -931,6 +931,52 @@
 	f_clear_m3ua();
 }
 
+/* Expect a normal ASP to reject any [S]SNM messages in ASP-INACTIVE state */
+testcase TC_clnt_no_snm_inactive() runs on RAW_M3UA_CT {
+	f_init_m3ua();
+	f_quirk("no_notify");
+	f_quirk("daud_in_asp");
+	f_no_quirk("snm_inactive");
+	f_init_m3ua_srv();
+
+	/* bring ASP only UP (into INACTIVE state), but not ACTIVE! */
+	f_M3UA_CLNT_asp_up(M3UA_SRV(0));
+	f_M3UA_exp(M3UA_SRV(0), tr_M3UA_ASPAC(*, *));
+
+	var template (value) M3UA_Point_Codes aff_pcs := { ts_M3UA_PC(mp_m3ua_configs[M3UA_SRV(0)].point_code) };
+	f_M3UA_send(M3UA_SRV(0), ts_M3UA_DAUD(aff_pcs));
+	f_M3UA_exp(M3UA_SRV(0), tr_M3UA_ERR('00000006'O, omit));
+	setverdict(pass);
+
+	f_no_quirk("no_notify");
+	f_no_quirk("daud_in_asp");
+	f_clear_m3ua();
+}
+
+/* quirk 'snm_inactive': Process [S]SNM in ASP-INACTIVE state */
+testcase TC_clnt_quirk_snm_inactive() runs on RAW_M3UA_CT {
+	f_init_m3ua();
+	f_quirk("no_notify");
+	f_quirk("daud_in_asp");
+	f_quirk("snm_inactive");
+	f_init_m3ua_srv();
+
+	/* bring ASP only UP (into INACTIVE state), but not ACTIVE! */
+	f_M3UA_CLNT_asp_up(M3UA_SRV(0));
+	f_M3UA_exp(M3UA_SRV(0), tr_M3UA_ASPAC(*, *));
+
+	var template (value) M3UA_Point_Codes aff_pcs := { ts_M3UA_PC(mp_m3ua_configs[M3UA_SRV(0)].point_code) };
+	f_M3UA_send(M3UA_SRV(0), ts_M3UA_DAUD(aff_pcs));
+	f_M3UA_exp(M3UA_SRV(0), tr_M3UA_DAVA(aff_pcs));
+	setverdict(pass);
+
+	f_no_quirk("no_notify");
+	f_no_quirk("daud_in_asp");
+	f_no_quirk("snm_inactive");
+	f_clear_m3ua();
+}
+
+
 control {
 	/* M3UA Tests */
 	execute( TC_connect_asp_up() );
@@ -968,6 +1014,8 @@
 		execute( TC_clnt_quirk_no_notify_asp_act() );
 		execute( TC_clnt_no_daud_in_asp() );
 		execute( TC_clnt_quirk_daud_in_asp() );
+		execute( TC_clnt_no_snm_inactive() );
+		execute( TC_clnt_quirk_snm_inactive() );
 	}
 
 	/* M3UA SSNM tests */

-- 
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/24230
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: Ic2a41e450a44794c8cf1c5a29871655f2cca4f6b
Gerrit-Change-Number: 24230
Gerrit-PatchSet: 1
Gerrit-Owner: laforge <laforge at osmocom.org>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210513/8255a55c/attachment.htm>


More information about the gerrit-log mailing list