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/.
lynxis lazus gerrit-no-reply at lists.osmocom.orglynxis lazus has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/24580 )
Change subject: NS_Tests: add test case TC_sns_bss_add_change_del
......................................................................
NS_Tests: add test case TC_sns_bss_add_change_del
1. do SNS configuration
2. add a bind
3. receive the SNS_ADD
4. before answering the SNS_ADD, change the weight via vty and remove the bind
Change-Id: Ibc565bba4c7e0a0b4dd28a48847dbdb998c8528d
---
M ns/NS_Tests.ttcn
1 file changed, 46 insertions(+), 0 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/80/24580/1
diff --git a/ns/NS_Tests.ttcn b/ns/NS_Tests.ttcn
index 3971f0d..6d53bd8 100644
--- a/ns/NS_Tests.ttcn
+++ b/ns/NS_Tests.ttcn
@@ -580,6 +580,51 @@
f_clean_ns_codec();
}
+/* 1. do SNS configuration
+ * 2. add a bind
+ * 3. receive the SNS_ADD
+ * 4. before answering the SNS_ADD, change the weight via vty and remove the bind
+ */
+testcase TC_sns_bss_add_change_del() runs on RAW_Test_CT {
+ var PDU_NS rx;
+ var NSVCConfiguration nsvc_cfg;
+
+ g_handle_rx_alive := true;
+ f_init_vty();
+ f_init_ns_codec(mp_nsconfig);
+ f_init_ns_codec(mp_nsconfig, 1);
+ f_incoming_sns_size();
+ f_incoming_sns_config();
+ f_outgoing_sns_config();
+ activate(as_rx_alive_tx_ack());
+ f_vty_config2(NSVTY, {"ns", "nse " & int2str(g_nsconfig.nsei)}, "ip-sns-bind local2");
+
+
+ nsvc_cfg := g_nsconfig.nsvc[1];
+ if (nsvc_cfg.provider.ip.address_family == AF_INET) {
+ var template (omit) IP4_Elements v4_elem := { ts_SNS_IPv4(nsvc_cfg.provider.ip.remote_ip,
+ nsvc_cfg.provider.ip.remote_udp_port,
+ 1, 1) };
+ rx := f_ns_exp(tr_SNS_ADD(g_nsconfig.nsei, ?, v4 := v4_elem), 0);
+ } else {
+ var template (omit) IP6_Elements v6_elem := { ts_SNS_IPv6(nsvc_cfg.provider.ip.remote_ip,
+ nsvc_cfg.provider.ip.remote_udp_port,
+ 1, 1) };
+ rx := f_ns_exp(tr_SNS_ADD(g_nsconfig.nsei, ?, omit, v6_elem), 0);
+ }
+
+ /* delete the endpoint */
+ f_vty_config2(NSVTY, {"ns", "bind udp local2"}, "ip-sns signalling-weight 99 data-weight 99");
+ f_vty_config2(NSVTY, {"ns", "nse " & int2str(g_nsconfig.nsei)}, "no ip-sns-bind local2");
+ NSCP[0].send(ts_SNS_ACK(g_nsconfig.nsei, rx.pDU_SNS_Add.transactionID));
+
+ //f_ns_exp(tr_SNS_CHG_WEIGHT(g_nsconfig.nsei, ?, ?, ?), 0)
+ f_incoming_sns_chg_weight(idx_chg := 1);
+ f_incoming_sns_del(idx_del := 1, w_sig := 99, w_user := 99);
+ setverdict(pass);
+ f_clean_ns_codec();
+}
+
control {
if (mp_dialect == NS2_DIALECT_STATIC_RESETBLOCK or mp_dialect == NS2_DIALECT_IPACCESS) {
execute( TC_tx_reset() );
@@ -629,6 +674,7 @@
execute( TC_sns_bss_change_weight_timeout() );
execute( TC_sns_bss_add() );
execute( TC_sns_bss_del() );
+ execute( TC_sns_bss_add_change_del() );
}
}
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/24580
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: Ibc565bba4c7e0a0b4dd28a48847dbdb998c8528d
Gerrit-Change-Number: 24580
Gerrit-PatchSet: 1
Gerrit-Owner: lynxis lazus <lynxis at fe80.eu>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210606/59e4432e/attachment.htm>