Commit Graph

2739 Commits

Author SHA1 Message Date
Vadim Yanitskiy 46cf8242d2 PCU_Tests: add a simple test case for OS#4844
Change-Id: If1961b284cce66e47870ea86ee7965ab2a27a9dc
2021-02-20 18:29:20 +01:00
Alexander Couzens 2efeb61139 gbproxy: update sns configuration to use ip-sns-bind
With libosmocore commit the SNS configuration requires a ip-sns-bind vty configuration
to define the binds which should be use.

Related: SYS#5354
Depends-on: I9ab8092bf286e7d90e92f5702a5404425e959c84 (libosmocore)
Change-Id: If86fe463199bc5089db80a0dcc01f9e94e23e9b9
2021-02-19 10:42:03 +00:00
Pau Espin 1303577b72 pcu: Introduce test TC_nacc_outbound_pkt_cell_chg_notif_nonassigned_dl_tbf
Triggers osmo-pcu assert in nacc_fsm.c due to scheduler not checking if
tbf has TFI assigned before deciding to transmit NACC related messages.

Related: osmo-pcu.git Change-Id I72b2dff28aacdb04909c098c94834ff79f55b31d
Related: SYS#4909
Change-Id: Id293e41e6b4380f2794007779ad430544bbe578a
2021-02-18 17:41:21 +01:00
Pau Espin Pedrol 28652d8724 Implement SystemInformation13 Rest Octets types
Related: SYS#5358
Change-Id: Id8845ebe28a9a6ed79d2d408dc7c1ad8a275b809
2021-02-17 17:08:28 +01:00
Harald Welte dd9fb84b58 sgsn: Fix regression regarding g_pars.bssgp.cell_id[] array overflow
This was introduced in I7d859fd710dba96eb9b46c428243281183e1be12
and caused Iu related TTCN3 tests to fail with:

SGSN_Tests.ttcn:771 Dynamic test case error: Index overflow in a value of type @SGSN_Tests.BssgpCellIds: The index is 3, but the value has only 3 elements.

Change-Id: Iaae0015f5e7c7eabc426add91b5de1b63bf6d9f6
2021-02-16 20:43:56 +01:00
Harald Welte a8dc198705 update AF_PACKET dependency to 0.1-5-g89ebea6
This includes the fix of https://gerrit.osmocom.org/c/titan.TestPorts.AF_PACKET/+/22934
which makes fr <-> fr-net pass again.

Change-Id: Ifa551fc9df340c9a02176f6644fa8ec4884431ae
2021-02-16 19:03:21 +00:00
Harald Welte 37202770e5 NS_Provider_FR: Fix typos in log lines
Change-Id: I5661ba61dc0de78bc480c49d4aba6436a8694706
2021-02-16 19:03:21 +00:00
Pau Espin 7c05216e01 sgsn: Introduce tests for several cell change related scenarios
Test TC_cell_change_different_ci_data provides test case for
fix in osmo-sgsn.git Change-Id I2c14e1d65575f54212924f7c5f0a2f4c1b76ec81

Related: SYS#4909
Change-Id: I2158685bf817d4bf064bb4d2ef5aa96ca252fe21
2021-02-16 17:31:37 +01:00
Harald Welte c56800066d NS_Emulation: Work around "alive" race condition in IP-SNS
We need to modify the state of each NS-VC within a NS-VCG/NSE once
we receive the final SNS-CONFIG-ACK PDU.  However, sometimes the
IUT sends its first NS-PDU _before_ we even have communicated the
state-change locally to all our NS-VCs.

In order to avoid the problem, let's mark the NS-VCs as alive before
sending the the SNS-CONFIG.  This means we have one RTT more time
to locally propagate the state change to all NS-VCs.

Change-Id: Idac522a81f01553df52dc012cbab15e1c73c0862
Closes: OS#5023
2021-02-13 16:49:25 +01:00
Harald Welte 516c5c7250 NS_Emulation: factor-out as_ns_common_status() altstep
This is a new altstep which groups all handling of NsStatusInd.
Right now it's only used from one place, but upcoming patches
will re-use it elsewhere.

Change-Id: I4e8e7d19c764cc977beb84a6859c9ce73518b653
2021-02-13 16:49:25 +01:00
Harald Welte 3bd182f3b3 NS_Emulation: Factor-out function to broadcast to all NS_VCs
Change-Id: I8cd16031dbbd244dcff74fc8a1cd69e9f8a06dbf
2021-02-13 16:49:25 +01:00
Harald Welte e5d41540d9 gbproxy: Fix configuration (ip-sns syntax)
It's sad that this config file has again been forgotten.

Change-Id: Ic9184669f6459c44fbb81e05b54028eca1b54db5
Related: SYS#5354
2021-02-13 16:49:25 +01:00
Pau Espin Pedrol 179ddef0f1 pcu: Introduce several tests TC_nacc_outbound_pkt_cell_chg_notif_twice*
These tests verify the NACC FSM adapts to MS restarting the NACC
procedure at any point when it selects for another tgt cell.

Related: SYS#4909
Change-Id: I42908a00f8d076e3559efde298a739d6b26d090e
2021-02-13 08:20:20 +00:00
Pau Espin Pedrol 0d6ebb7f2c pcu: Introduce several tests TC_nacc_outbound_pkt_cell_chg_notif_dup*
These tests verify retransmission of duplicated Pkt Cell Change
Notification messages are ignored once the NACC procedure is already
ongoig.

Related: SYS#4909
Change-Id: Ib83eacfab7a73a2a51ab08801ff1c00c0058057c
2021-02-13 08:20:20 +00:00
Pau Espin Pedrol 6cb71cc2e0 pcu: Convert f_handle_pkt_neighbor_cell_data impl to use alt statements
Change-Id: Iac9306cdcf16d9eaa750f6ca10f0c9df6f2c7453
2021-02-13 08:20:20 +00:00
Pau Espin d792b9e122 sgsn: Fix f_process_attach_accept on ran_index != 0
Change-Id: I7d859fd710dba96eb9b46c428243281183e1be12
2021-02-12 20:15:02 +01:00
Pau Espin deaaa90e43 sgsn: Fix f_cellid_to_RAI
Change-Id: I4f6d609119b4a9e211fb1b285e4fc3e42d8ebdb6
2021-02-12 18:48:47 +01:00
Pau Espin Pedrol d4ed360dbf pcu: Introduce tests checking Pkt Cell Chg Notif different msg retrans
Tests verify MS retransmitting a Pkt cell Chg Notif with different
target cell (hence a different NACC procedure) will be handled correctly
if PCU state was in the middle of handling a different NACC request.

Related: SYS#4909

Change-Id: I68c749aaabe9fe8272fc43045be09a46852359e5
2021-02-12 14:40:54 +00:00
Pau Espin Pedrol 6a71548d47 pcu: Introduce tests checking Pkt Cell Chg Notif dup retrans
Tests verify dup retrans triggered by MS timer are ignored if the target
cell is still the same (and hence no logic/behavior change is required,
current process can proceed onwards).

Related: SYS#4909
Change-Id: I00e8c1a63392bf8753f58f7d9d2d0e903ac5c529
2021-02-12 14:40:54 +00:00
Daniel Willmann c879f3416f gbproxy: Increase timeouts for dl/ul unitdata tests
These tests run quite some time and I had issues with timeouts locally.

Change-Id: Id99ffa14bf6bcb584688c410feb9163a4f0fb492
2021-02-11 15:17:14 +01:00
Daniel Willmann 325458ddf7 gbproxy: Fix TC_dl_unitdata test failure introduced by 6ee0126971
This commit used a send template (ts) to match a received BSSGP PDU which
doesn't work due to some differences in the length field.
Use tr_BSSGP_IMSI again and change the template restrictions so it
compiles.

Fixes: 6ee0126971
Change-Id: I85676e96f8d32a9d2c7deadc1d66707b6b8697d0
2021-02-11 15:16:57 +01:00
Harald Welte 24f921baea sccp: Add Tests for SCMG SST procedure
The SST procedure can be used by any SCCP node to test the availability
of a remote SSN.  If the specified remote SSN is available at the
specified PC, a SCMG SSA is returned.  If not, there's a timeout.

Test for SSN=1 (SCMG), another non-SCMG SSN that exists, and for one
SSN that doesn't exist.

Change-Id: If3f5f3144c0ed83d0bda5953522a9d73287c8ba2
2021-02-11 12:00:29 +00:00
Harald Welte e92cc66c62 SCCP_Templates: Make tr_SCCP_UDT work for unspecific templates
Change-Id: Ic77f52f7ec6dc8e17d9cd0789ba790296a25bc50
2021-02-11 12:00:29 +00:00
Philipp Maier 1bd60ce2b8 GBProxy_Tests: fix TC_rim_info_pcu2pcu
The testcase TC_rim_info_pcu2pcu calls a function f_TC_rim_info_pcu2pcu()
which doesn't use the templates from Osmocom_Gb_Types.ttcn as intended.
This eventually lets the altstep in f_rim_pcu2pcu() run into a timeout
since the templates never match.

Change-Id: I281dc53bb5dd7be86edc9db185618252ff1b9a21
Related: SYS#5103
2021-02-10 20:08:14 +01:00
Daniel Willmann 9fda2145e0 gbproxy: Fix ip-sns VTY config
Change-Id: Ia826ec4b5045360c1b37826f86f03bdccaf63360
Related: SYS#5354
Depends: Ida979f3b9daa5f7280a629441e4006a7635653b0 (libosmocore.git)
2021-02-10 13:53:48 +01:00
Harald Welte 7534fbff40 deps/Makefile: Update SCCP dependency
* upstream has merged all two Osmocom patches
* we can now switch back to the official repo instead of our fork

Change-Id: Ia9bc82db4c0814b06c55460d2123b5e4fa1a2335
2021-02-10 09:25:33 +01:00
Alexander Couzens 98ee6f6507 pcu: move generic RAW_NS_CT function to library/RAW_NS
Allow the NS tests to use the SNS functions.

Change-Id: I6c404475f39dd00023eb11e98da93ee423604039
2021-02-09 15:49:15 +01:00
Vadim Yanitskiy 109e755161 msc: test reaction on Clear Request during a MO/MT Call
Change-Id: Id16969fe0de04445d1320a96d35cf1d48cc8cf09
Related: SYS#5340
2021-02-08 20:18:13 +00:00
Vadim Yanitskiy b56701e021 msc: finish and enable test case for MT Call T310 timer
The test suite needs to handle MGCP messages, otherwise the related
FSMs in the IUT would tear everything down before T310 is expired.

Change-Id: I79d9ae3b086d05c3d7c0a1241720d6c3f1e90281
Related: SYS#5340
2021-02-08 20:18:13 +00:00
Pau Espin Pedrol 3bc82b494a VTY: Fix warning: control reaches end of non-void function
Change-Id: Ie9415afecbcaf12e210fd4f481fcbb1f5ba52c77
2021-02-08 18:43:17 +01:00
Pau Espin Pedrol 0af478ebe1 pcu: TC_rim_ran_info_req_single_rep: don't duplicate si_default locally
The same values are available for several tests as gloval consts.

Change-Id: I32b7d841bc1fa896f9866c5d7fba857e1ca65ab3
2021-02-08 18:35:38 +01:00
Pau Espin Pedrol fa64e2885b Fix tons of warnings in RLCMAC and pcu
Change-Id: Ia3b7c5f9fdf571f99859027dbab8731ea1a8e830
2021-02-08 18:35:38 +01:00
Harald Welte 27cfb7a230 stp: Introduce M3UA SSNM tests
Tests for M3UA SSNM behavior.  This is just being introduced in
osmo-stp, so all tests will fail on 'latest', and some will still fail
until SSNM processing inside osmo-stp is becoming more complete.

Change-Id: I5074dccde9940956439235e8d02e6a722b8da5f5
Related: OS#2623
2021-02-08 17:22:26 +00:00
Harald Welte 1c4e984765 stp: Less magic numbers; centralize M3UA configuration
We shouldn't be having magic numbers for point codes etc. in each
test case.

Change-Id: Id8a6241657e1f02f15d6722934eb040fc98beab1
2021-02-08 17:22:08 +00:00
Harald Welte 308125957a stp: Time out after 5s if expected M3UA doesn't arrive
No need to wait for the global timeout here.

Change-Id: I279aacf2215ccd63a6e52c6a71cda3b500a3795c
2021-02-08 17:21:58 +00:00
Harald Welte 42bcc44153 stp: Ignore M3UA SSNM messages in tests
The tests were written without considering the arrival of such messages;
however, it is well within the M3UA spec that such messages appear at
any time indicating remote point code availability etc.

In libosmo-sccp.git Id92be4691b0fd77598a6edb642c028bbd8c5b623 we start
generating those messages in osmo-stp.

Let's ignore them in the tests to avoid unexpected failures.

Later on, we likely will introduce / adapt tests to actually expect
those messages whenever appropriate.

Change-Id: I85ce8fd4f26db184833cf348293f0255bb5eaac3
Related: OS#2623
2021-02-08 17:15:15 +00:00
Pau Espin Pedrol fb14690c81 StatsD_Checker: Check f_IPL4_listen result
Change-Id: Ief4e30ae92b8567dd9618064220f9f50df2d0de0
2021-02-08 12:36:42 +01:00
Pau Espin Pedrol 6ee0126971 Osmocom_Gb_Types: Fix tons of template restriction warnings
Change-Id: I3da153ce5e83b231501e74b958fcac9f10c00849
2021-02-08 12:32:07 +01:00
Pau Espin Pedrol 7e88ce91d4 Osmocom_Gb_Types: Fix warning: control reaches end of non-void function
Change-Id: Ic2b8d0215c378ec2fd1a44775dc4e43616ca9f3c
2021-02-08 12:32:07 +01:00
Pau Espin Pedrol fceeec27ce pcu: Fix warning: control reaches end of non-void function
Change-Id: I2c8b343fba5fabda9f78af8711e2a837536518e9
2021-02-08 12:32:07 +01:00
Pau Espin Pedrol 3855462672 GSM_Types: Fix warning: control reaches end of non-void function
Change-Id: I749fe3a2ca85ae96fa74a78f15180cfaa02ffe84
2021-02-08 12:32:07 +01:00
Pau Espin Pedrol 810b1df0d8 Osmocom_Gb_Types: Fix warning: inadequate restriction on the referenced function
Fixes warning:
Osmocom_Gb_Types.ttcn:1377.13-32: warning: Inadequate restriction on the
referenced function `f_oct_or_wc(bmax, 2)', this may cause a dynamic test
case error at runtime

Change-Id: Icb8698c7f2ca697a3638d5a4e4e38f20e14fd34c
2021-02-08 12:32:07 +01:00
Pau Espin Pedrol 1b31ba4658 pcu: Fix inadequate restriction on the referenced template parameter
warning: Inadequate restriction on the referenced template parameter `imsi'

Change-Id: Iecd19d8d397e427068e495577889e1247faa11e7
2021-02-08 12:32:07 +01:00
Pau Espin Pedrol dbc71270df pcu: Fix inadequate restriction on the referenced template parameter
Fixes:
warning: Inadequate restriction on the referenced template parameter
`tfi', this may cause a dynamic test case error at runtime

Same for other parameters.

Change-Id: If2cadbc7087ac0f99537b9916ef0c23363c9242c
2021-02-08 12:32:07 +01:00
Pau Espin Pedrol db317650b4 pcu: Fix inadequate restriction on the referenced template parameter
Fixes:
 warning: Inadequate restriction on the referenced template parameter
 `chreq_desc', this may cause a dynamic test case error at runtime

Change-Id: I10b170c13aedc8abaaaf3b67d563ade8c3586c5b
2021-02-08 12:32:07 +01:00
Pau Espin Pedrol 40a0295382 CTRL: Avoid using keyword 'now' as var
Fixes warning: Keyword 'now' is treated as an identifier. Activate
compiler option '-I' to use real-time testing features

Change-Id: I2b350bc93b33f36f72d35cb48d01f6c37ac1630f
2021-02-08 12:32:07 +01:00
Pau Espin Pedrol 847a1651cd BSSGP_Emulation: Fix indentation whitespace
Change-Id: Iade336832e7045cd29bae52c7907c6a1c57813cd
2021-02-08 12:32:07 +01:00
Pau Espin Pedrol 011e32f8fc BSSGP_Emulation: Fix warning: control reaches end of non-void function
Change-Id: I9a44afc81b5b6b35a32a12efcf2dd1cb15e73e12
2021-02-08 12:31:14 +01:00
Alexander Couzens 03f6606181 pcu: fix syntax in PCU_Tests.cfg
There was a missing comma in the configuration as well the
indention was misaligned.

Related: OS#4953
Fixes: be7afce974 ("NS_Emulation: Respect data_weight==0 or signalling_weight==0")
Change-Id: I7f146ff71c107983e5787982970d0f6cd313cde9
2021-02-05 20:45:52 +00:00
Harald Welte 49f3ea818b NS_Provider_FR: Drop received messages until limk+pvc are up
Related: OS#4974
Change-Id: I69f9cf485b0a9eaf9294236f50ffcf4af20f1d20
2021-02-05 21:05:14 +01:00