|
|
|
@ -44,6 +44,20 @@ modulepar { |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
nsvci := 97 |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
provider := { |
|
|
|
|
ip := { |
|
|
|
|
address_family := AF_INET, |
|
|
|
|
local_udp_port := 21000, |
|
|
|
|
local_ip := "127.0.0.1", |
|
|
|
|
remote_udp_port := 23001, |
|
|
|
|
remote_ip := "127.0.0.1", |
|
|
|
|
data_weight := 1, |
|
|
|
|
signalling_weight := 1 |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
nsvci := 98 |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
}; |
|
|
|
@ -58,6 +72,7 @@ private function f_init_vty() runs on RAW_Test_CT { |
|
|
|
|
f_vty_set_prompts(NSVTY); |
|
|
|
|
f_vty_transceive(NSVTY, "enable"); |
|
|
|
|
f_vty_transceive(NSVTY, "nsvc nsei " & int2str(mp_nsconfig.nsei) & " force-unconfigured"); |
|
|
|
|
f_vty_config2(NSVTY, {"ns", "nse " & int2str(mp_nsconfig.nsei)}, "no ip-sns-bind local2"); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
/* ensure no matching message is received within 'tout' */ |
|
|
|
@ -527,6 +542,42 @@ testcase TC_sns_bss_change_weight_timeout() runs on RAW_Test_CT { |
|
|
|
|
f_clean_ns_codec(); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
testcase TC_sns_bss_add() runs on RAW_Test_CT { |
|
|
|
|
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"); |
|
|
|
|
f_incoming_sns_add(idx_add := 1); |
|
|
|
|
as_rx_alive_tx_ack(oneshot := true, idx := 1); |
|
|
|
|
setverdict(pass); |
|
|
|
|
f_clean_ns_codec(); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
testcase TC_sns_bss_del() runs on RAW_Test_CT { |
|
|
|
|
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"); |
|
|
|
|
f_incoming_sns_add(idx_add := 1); |
|
|
|
|
as_rx_alive_tx_ack(oneshot := true, idx := 1); |
|
|
|
|
|
|
|
|
|
/* delete the endpoint */ |
|
|
|
|
f_vty_config2(NSVTY, {"ns", "nse " & int2str(g_nsconfig.nsei)}, "no ip-sns-bind local2"); |
|
|
|
|
f_incoming_sns_del(idx_del := 1); |
|
|
|
|
setverdict(pass); |
|
|
|
|
f_clean_ns_codec(); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
control { |
|
|
|
|
if (mp_dialect == NS2_DIALECT_STATIC_RESETBLOCK or mp_dialect == NS2_DIALECT_IPACCESS) { |
|
|
|
|
execute( TC_tx_reset() ); |
|
|
|
@ -574,6 +625,8 @@ control { |
|
|
|
|
execute( TC_sns_config_success() ); |
|
|
|
|
execute( TC_sns_bss_change_weight() ); |
|
|
|
|
execute( TC_sns_bss_change_weight_timeout() ); |
|
|
|
|
execute( TC_sns_bss_add() ); |
|
|
|
|
execute( TC_sns_bss_del() ); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|