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/.
Harald Welte gerrit-no-reply at lists.osmocom.orgHarald Welte has submitted this change and it was merged. ( https://gerrit.osmocom.org/13027 ) Change subject: PCU: Add test for SNS Change Weight procedure ...................................................................... PCU: Add test for SNS Change Weight procedure Change-Id: Ia63865139f63969ccde010b01ddb8fb073209f3a --- M library/Osmocom_Gb_Types.ttcn M pcu/PCU_Tests_RAW_SNS.ttcn 2 files changed, 46 insertions(+), 0 deletions(-) Approvals: Jenkins Builder: Verified Harald Welte: Looks good to me, approved diff --git a/library/Osmocom_Gb_Types.ttcn b/library/Osmocom_Gb_Types.ttcn index a0242c3..780c768 100644 --- a/library/Osmocom_Gb_Types.ttcn +++ b/library/Osmocom_Gb_Types.ttcn @@ -613,6 +613,29 @@ } } + template (value) PDU_NS ts_SNS_CHG_WEIGHT(Nsei nsei, uint8_t trans_id, + template (omit) IP4_Elements v4, + template (omit) IP6_Elements v6 := omit) := { + pDU_SNS_ChangeWeight := { + nsPduType := '0E'O, + nSEI_NS := ts_NS_IE_NSEI(nsei), + transactionID := trans_id, + listofIP4Elements := ts_SNS_IE_ListIP4(v4), + listofIP6Elements := ts_SNS_IE_ListIP6(v6) + } + } + template PDU_NS tr_SNS_CHG_WEIGHT(template Nsei nsei, template uint8_t trans_id, + template IP4_Elements v4, + template IP6_Elements v6 := omit) := { + pDU_SNS_ChangeWeight := { + nsPduType := '0E'O, + nSEI_NS := tr_NS_IE_NSEI(nsei), + transactionID := trans_id, + listofIP4Elements := tr_SNS_IE_ListIP4(v4), + listofIP6Elements := tr_SNS_IE_ListIP6(v6) + } + } + template (value) PDU_NS ts_SNS_ACK(Nsei nsei, uint8_t trans_id, template (omit) NsCause cause := omit, diff --git a/pcu/PCU_Tests_RAW_SNS.ttcn b/pcu/PCU_Tests_RAW_SNS.ttcn index 41a4059..2369b04 100644 --- a/pcu/PCU_Tests_RAW_SNS.ttcn +++ b/pcu/PCU_Tests_RAW_SNS.ttcn @@ -89,6 +89,19 @@ rx := f_ns_exp(tr_SNS_ACK(g_nsconfig[idx].nsei, 24, omit, v4)); } +function f_outgoing_sns_chg_weight(integer idx_chg, uint8_t w_sig, uint8_t w_user, integer idx := 0) +runs on RAW_NS_CT { + log("f_outgoing_sns_chg_weight(idx_chg=", idx_chg, ")"); + var PDU_NS rx; + var template (omit) IP4_Elements v4 := { ts_SNS_IPv4(g_nsconfig[idx_chg].local_ip, + g_nsconfig[idx_chg].local_udp_port, + w_sig, w_user) }; + NSCP[idx].send(t_NS_Send(g_ns_conn_id[idx], ts_SNS_CHG_WEIGHT(g_nsconfig[idx].nsei, 25, v4))); + rx := f_ns_exp(tr_SNS_ACK(g_nsconfig[idx].nsei, 25, omit, v4)); +} + + + /* PCU-originated SNS-SIZE: successful case */ @@ -225,6 +238,15 @@ setverdict(pass); } +/* Test changing weights at runtime */ +testcase TC_sns_chg_weight() runs on RAW_NS_CT { + f_sns_bringup_1c1u(); + + /* change w_user from 1 to 200 */ + f_outgoing_sns_chg_weight(idx_chg := 1, w_sig := 0, w_user := 200, idx := 0); + setverdict(pass); +} + control { @@ -236,6 +258,7 @@ execute( TC_sns_1c1u() ); execute( TC_sns_add() ); execute( TC_sns_del() ); + execute( TC_sns_chg_weight() ); } } -- To view, visit https://gerrit.osmocom.org/13027 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-ttcn3-hacks Gerrit-Branch: master Gerrit-MessageType: merged Gerrit-Change-Id: Ia63865139f63969ccde010b01ddb8fb073209f3a Gerrit-Change-Number: 13027 Gerrit-PatchSet: 2 Gerrit-Owner: Harald Welte <laforge at gnumonks.org> Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org> Gerrit-Reviewer: Jenkins Builder (1000002) Gerrit-CC: Pau Espin Pedrol <pespin at sysmocom.de> -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20190226/dc9416d4/attachment.htm>