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/.
Vadim Yanitskiy gerrit-no-reply at lists.osmocom.orgVadim Yanitskiy has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/18355 ) Change subject: library/IPA: split t_ASP_IPA_EVT_UD into send / receive templates ...................................................................... library/IPA: split t_ASP_IPA_EVT_UD into send / receive templates Change-Id: Ib5494bff3f9aa0ac396b729c326e7b4a64c5a5dd --- M bts/BTS_Tests_OML.ttcn M hlr/HLR_Tests.ttcn M library/IPA_Emulation.ttcnpp M msc/MSC_Tests.ttcn M remsim/RemsimClient_Tests.ttcn M remsim/RemsimServer_Tests.ttcn M selftest/Selftest.ttcn M sgsn/SGSN_Tests.ttcn 8 files changed, 25 insertions(+), 21 deletions(-) Approvals: laforge: Looks good to me, approved Jenkins Builder: Verified diff --git a/bts/BTS_Tests_OML.ttcn b/bts/BTS_Tests_OML.ttcn index 84d46a4..4835e66 100644 --- a/bts/BTS_Tests_OML.ttcn +++ b/bts/BTS_Tests_OML.ttcn @@ -102,8 +102,8 @@ T_oml_guard.start; activate(as_Tguard()); - OML.receive(t_ASP_IPA_EVT_UD(ASP_IPA_EVENT_UP)); - //OML.receive(t_ASP_IPA_EVT_UD(ASP_IPA_EVENT_ID_ACK)); + OML.receive(tr_ASP_IPA_EV(ASP_IPA_EVENT_UP)); + //OML.receive(tr_ASP_IPA_EV(ASP_IPA_EVENT_ID_ACK)); activate(as_SwAct()); activate(as_IPA_evt()); diff --git a/hlr/HLR_Tests.ttcn b/hlr/HLR_Tests.ttcn index 06354b9..27a44de 100644 --- a/hlr/HLR_Tests.ttcn +++ b/hlr/HLR_Tests.ttcn @@ -200,7 +200,7 @@ timer T := 10.0; T.start; alt { - [not legacy] GSUP_IPA_EVENT.receive(t_ASP_IPA_EVT_UD(ASP_IPA_EVENT_UP)) { } + [not legacy] GSUP_IPA_EVENT.receive(tr_ASP_IPA_EV(ASP_IPA_EVENT_UP)) { } [legacy] GSUP.receive(ASP_IPA_Event:{up_down := ASP_IPA_EVENT_UP}) { } [] T.timeout { setverdict(fail, "No connection to GSUP Port"); diff --git a/library/IPA_Emulation.ttcnpp b/library/IPA_Emulation.ttcnpp index 6658ca8..0edc0a7 100644 --- a/library/IPA_Emulation.ttcnpp +++ b/library/IPA_Emulation.ttcnpp @@ -88,7 +88,11 @@ ASP_IPA_EventType up_down } -template ASP_IPA_Event t_ASP_IPA_EVT_UD(ASP_IPA_EventType ud) := { +template (value) ASP_IPA_Event ts_ASP_IPA_EV(ASP_IPA_EventType ud) := { + up_down := ud +} + +template ASP_IPA_Event tr_ASP_IPA_EV(template ASP_IPA_EventType ud) := { up_down := ud } @@ -291,7 +295,7 @@ data := char2oct(payload) & '00'O } -private function f_send_IPA_EVT(template ASP_IPA_Event evt) runs on IPA_Emulation_CT { +private function f_send_IPA_EVT(template (value) ASP_IPA_Event evt) runs on IPA_Emulation_CT { if (IPA_SP_PORT.checkstate("Connected")) { IPA_SP_PORT.send(evt); } @@ -410,7 +414,7 @@ f_ccm_tx(valueof(ts_IPA_PONG)); } case (IPAC_MSGT_ID_ACK) { - f_send_IPA_EVT(t_ASP_IPA_EVT_UD(ASP_IPA_EVENT_ID_ACK)); + f_send_IPA_EVT(ts_ASP_IPA_EV(ASP_IPA_EVENT_ID_ACK)); } case (IPAC_MSGT_ID_GET) { f_ccm_tx(f_ccm_make_id_resp(ccm)); @@ -432,7 +436,7 @@ * the TCP connection is established. Other implementations may differ. * We currently ignore it completely - but actually we should make sure that * one ID_ACK is received by the server at some point */ - f_send_IPA_EVT(t_ASP_IPA_EVT_UD(ASP_IPA_EVENT_ID_ACK)); + f_send_IPA_EVT(ts_ASP_IPA_EV(ASP_IPA_EVENT_ID_ACK)); } case (IPAC_MSGT_ID_RESP) { log("IPA ID RESP: ", ccm.u.resp); @@ -488,7 +492,7 @@ /* we're a client: Send ID_ACK immediately after connect */ f_ccm_tx(valueof(ts_IPA_ACK)); } - f_send_IPA_EVT(t_ASP_IPA_EVT_UD(ASP_IPA_EVENT_UP)); + f_send_IPA_EVT(ts_ASP_IPA_EV(ASP_IPA_EVENT_UP)); ScanEvents(); } @@ -666,7 +670,7 @@ [] IPA_PORT.receive(ASP_Event:{connOpened:=?}) -> value asp_evt { log("IPA: Connected"); g_ipa_conn_id := asp_evt.connOpened.connId; - f_send_IPA_EVT(t_ASP_IPA_EVT_UD(ASP_IPA_EVENT_UP)); + f_send_IPA_EVT(ts_ASP_IPA_EV(ASP_IPA_EVENT_UP)); if (g_mode == IPA_MODE_SERVER and g_ccm_enabled) { select (g_init_behavior) { case (IPA_INIT_SEND_IPA_ID_GET) { @@ -682,14 +686,14 @@ [] IPA_PORT.receive(ASP_Event:{connClosed:=?}) -> value asp_evt { log("IPA: Closed"); g_ipa_conn_id := -1; - f_send_IPA_EVT(t_ASP_IPA_EVT_UD(ASP_IPA_EVENT_DOWN)); + f_send_IPA_EVT(ts_ASP_IPA_EV(ASP_IPA_EVENT_DOWN)); self.stop; } [] IPA_PORT.receive(Socket_API_Definitions.PortEvent:{result:={errorCode:=ERROR_SOCKET, connId:=?, os_error_code:=?, os_error_text:=?}}) -> value port_evt { log("PortEvent: ERROR_SOCKET: ", port_evt); g_ipa_conn_id := -1; - f_send_IPA_EVT(t_ASP_IPA_EVT_UD(ASP_IPA_EVENT_DOWN)); + f_send_IPA_EVT(ts_ASP_IPA_EV(ASP_IPA_EVENT_DOWN)); self.stop; } @@ -774,7 +778,7 @@ port IPA_SP_PT IPA_SP_PORT; } -function waiter_main(template ASP_IPA_Event wait_for := t_ASP_IPA_EVT_UD(ASP_IPA_EVENT_ID_ACK)) +function waiter_main(template ASP_IPA_Event wait_for := tr_ASP_IPA_EV(ASP_IPA_EVENT_ID_ACK)) runs on IPA_EventWaiter_CT { alt { diff --git a/msc/MSC_Tests.ttcn b/msc/MSC_Tests.ttcn index 084ae85..35ca84a 100644 --- a/msc/MSC_Tests.ttcn +++ b/msc/MSC_Tests.ttcn @@ -290,7 +290,7 @@ timer T := 10.0; T.start; alt { - [] GSUP_IPA_EVENT.receive(t_ASP_IPA_EVT_UD(ASP_IPA_EVENT_UP)) { } + [] GSUP_IPA_EVENT.receive(tr_ASP_IPA_EV(ASP_IPA_EVENT_UP)) { } [] T.timeout { setverdict(fail, "No connection to GSUP Port"); mtc.stop diff --git a/remsim/RemsimClient_Tests.ttcn b/remsim/RemsimClient_Tests.ttcn index 457e449..499fd3e 100644 --- a/remsim/RemsimClient_Tests.ttcn +++ b/remsim/RemsimClient_Tests.ttcn @@ -59,7 +59,7 @@ /* expect inbound connectClientReq */ as_connectClientReq(res := illegalClientId); /* expect disconnect by client */ - RSPRO_SRV[0].receive(t_ASP_IPA_EVT_UD(ASP_IPA_EVENT_DOWN)); + RSPRO_SRV[0].receive(tr_ASP_IPA_EV(ASP_IPA_EVENT_DOWN)); setverdict(pass); f_sleep(1.0); } @@ -139,7 +139,7 @@ f_rspro_config_client_bank(bslot, ts_IpPort(ts_IPv4("0.0.0.0"), 0)); /* expect disconnect of client on simulated bankd side */ - RSPRO_SRV[1].receive(t_ASP_IPA_EVT_UD(ASP_IPA_EVENT_DOWN)); + RSPRO_SRV[1].receive(tr_ASP_IPA_EV(ASP_IPA_EVENT_DOWN)); setverdict(pass); } @@ -162,7 +162,7 @@ f_rspro_config_client_bank(bslot, ts_IpPort(ts_IPv4("0.0.0.0"), 0)); /* expect disconnect of client on simulated bankd side */ - RSPRO_SRV[1].receive(t_ASP_IPA_EVT_UD(ASP_IPA_EVENT_DOWN)); + RSPRO_SRV[1].receive(tr_ASP_IPA_EV(ASP_IPA_EVENT_DOWN)); /* re-start the IPA emulation (which terminated itself on the TCP disconnect */ f_rspro_srv_init(1, mp_bankd_ip, mp_bankd_port, g_bankd_comp_id, exp_connect := false); diff --git a/remsim/RemsimServer_Tests.ttcn b/remsim/RemsimServer_Tests.ttcn index bada70a..1ca5ce9 100644 --- a/remsim/RemsimServer_Tests.ttcn +++ b/remsim/RemsimServer_Tests.ttcn @@ -164,8 +164,8 @@ T.start; /* expect that we're disconnected if we never send a ConnectClientReq */ alt { - [] RSPRO[0].receive(t_ASP_IPA_EVT_UD(ASP_IPA_EVENT_ID_ACK)) { repeat; } - [] RSPRO[0].receive(t_ASP_IPA_EVT_UD(ASP_IPA_EVENT_DOWN)) { + [] RSPRO[0].receive(tr_ASP_IPA_EV(ASP_IPA_EVENT_ID_ACK)) { repeat; } + [] RSPRO[0].receive(tr_ASP_IPA_EV(ASP_IPA_EVENT_DOWN)) { setverdict(pass); } [] T.timeout { diff --git a/selftest/Selftest.ttcn b/selftest/Selftest.ttcn index 8411b3d..263c317 100644 --- a/selftest/Selftest.ttcn +++ b/selftest/Selftest.ttcn @@ -46,8 +46,8 @@ function f_ipa_wait_up() runs on IPA_selftest_CT { interleave { - [] IPA_RSL.receive(t_ASP_IPA_EVT_UD(ASP_IPA_EVENT_UP)); - [] IPA_CTRL.receive(t_ASP_IPA_EVT_UD(ASP_IPA_EVENT_UP)); + [] IPA_RSL.receive(tr_ASP_IPA_EV(ASP_IPA_EVENT_UP)); + [] IPA_CTRL.receive(tr_ASP_IPA_EV(ASP_IPA_EVENT_UP)); } } diff --git a/sgsn/SGSN_Tests.ttcn b/sgsn/SGSN_Tests.ttcn index 6c963fa..9d191cc 100644 --- a/sgsn/SGSN_Tests.ttcn +++ b/sgsn/SGSN_Tests.ttcn @@ -232,7 +232,7 @@ timer T := 10.0; T.start; alt { - [] GSUP_IPA_EVENT.receive(t_ASP_IPA_EVT_UD(ASP_IPA_EVENT_UP)) { } + [] GSUP_IPA_EVENT.receive(tr_ASP_IPA_EV(ASP_IPA_EVENT_UP)) { } [] T.timeout { setverdict(fail, "No connection to GSUP Port"); mtc.stop; -- To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/18355 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: Ib5494bff3f9aa0ac396b729c326e7b4a64c5a5dd Gerrit-Change-Number: 18355 Gerrit-PatchSet: 1 Gerrit-Owner: Vadim Yanitskiy <axilirator at gmail.com> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: Vadim Yanitskiy <axilirator at gmail.com> Gerrit-Reviewer: laforge <laforge at osmocom.org> Gerrit-MessageType: merged -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20200518/f65919f8/attachment.htm>