Commit Graph

145 Commits

Author SHA1 Message Date
Vadim Yanitskiy 9f40fef768 ttcn3-bsc-test-sccplite: osmo-bsc.cfg: remove deprecated 'mgw remote-ip'
Change-Id: Ie322315dd1608636002d4003e5f8629925041476
2024-03-28 04:43:16 +07:00
Vadim Yanitskiy 0448871bac */osmo-bsc.cfg: BTS type 'sysmobts' (deprecated) -> osmo-bts
Change-Id: I98ea9e96d490473efbbe189842ed9f547060dc7d
2024-03-28 04:42:35 +07:00
Oliver Smith 6a8118dad8 ttcn3: use debian-bookworm-titan
Related: OS#6057
Change-Id: I2017dd3888670c475b96e692d911a433484f3df9
2023-08-14 09:28:24 +00:00
Pau Espin 2eb695bc44 */osmo-stp.cfg: Explicitly define role & sctp-role
It was recently decided it's a good practice to always specify the role
and sctp-role for all ASPs configured in the VTY, since it's an
important configuration providing feedback on the network setup
expectancies.

Change-Id: Ia495bc3c5dd4421e5730c74b2f5dc4e4cdc1a673
2023-07-05 13:48:55 +00:00
Pau Espin 7c0bb4e341 Explicitly configure ASPs asp-clnt-* as role=asp & sctp-role=client
Until recently, the asp-clnt-* ASPs, which have specific handling in osmo_sccp_simple_client_on_ss7_id(),
were being always forcedly set to sctp-role CLIENT by code in that
function.
This prevented user of that API from explicitly configuring the ASP as
"sctp-role server" through the VTY as the option would be overwritten silently.

Now, the sctp-role from config is followed if the ASP is
defined/configured through the VTY (not dynamically created at the time
osmo_sccp_simple_client_on_ss7_id() is called).

Since the default for a VTY-specified ASP is to be in "sctp-role
server", the config files need to be updated to properly configure the
ASP to be in "sctp-role client", which is the desired mode here.

Same applies for "role", where the default is SG but it is actually used
as "ASP" here.

Change-Id: Idf84502ffa199926a5f0ee616313b515743811ab
Depends: osmo-ttcn3-hacks.git Change-Id I4eb5b5f6b4b24df079b4c74e2a2e2ebb8769b0bd
2023-06-08 19:20:46 +02:00
Oliver Smith 8fd822ad17 ttcn3-bsc-test: sleep 1s before starting testsuite
Give OsmoBSC time to connect to OsmoSTP, so BSSMAP RESET from the
testsuite doesn't fail in OsmoSTP with:
  MTP-TRANSFER.req for DPC 187: no route!

Without this patch, it would fail every other time on my system when
only having one test enabled in BSC_Tests.cfg.

Change-Id: Ic7f80bdfe2fe58e93c2f2e3baa6d7645fcdc3062
2023-02-13 18:22:03 +01:00
Pau Espin 666488c8e4 ttcn3-*: Update test setup after Osmocom CNI release 202302
Change-Id: If34b043a55177e6c0d1be3949fc2a2682258cc84
2023-02-08 12:36:27 +01:00
Oliver Smith d2827d91ce network_create: put SUBNET in NET_NAME
Fix the bug that running a test twice on the same host results in the
second test stopping the containers and network of the first test:

* Have the subnet name in the network name, so there's no collision of
  network names when cleaning up the network.

* Don't clean up the network when creating a new network. Rely on the
  clean up trap to clean up the network instead.

* Don't set NET_NAME when sourcing jenkins-common.sh anymore, as
  network_create will set it. There's also network_bridge_create, which
  only gets used by osmo-ran (which we don't run in jenkins). Add a
  check to this function to ensure NET_NAME is set before calling it,
  which osmo-ran is already doing.

Related: OS#5802
Change-Id: Ifcd384272c56d585e220e2588f2186dc110902ed
2023-01-17 09:39:52 +01:00
Oliver Smith f997b4e771 network_create: find free subnet automatically
Try multiple subnet numbers until successfully creating a network. This
way we can run the same ttcn3 testsuite multiple times in parallel
without conflicts (e.g. once against latest, once against nightly). Also
we don't need to make sure each new testsuite has a unique subnet
number anymore.

I've considered also adjusting network_bridge_create, but that gets used
exclusively by osmo-ran/jenkins.sh, a script which we don't actually run
in jenkins. It seems that in this script it makes more sense to not get
a random subnet number.

Related: OS#5802
Change-Id: I57152b08ef0f38e17e7019a8df032189b03f56cf
2023-01-16 15:19:29 +00:00
Oliver Smith 4cb0fac1b0 ttcn3-*/jenkins*.sh: use $SUBNET everywhere
Use the SUBNET variable instead of hardcoding it in some places. Split
commands across multiple lines while at it to improve readability.

Related: OS#5802
Change-Id: I08f83089ef97f5f92d4bbfa5743301e7375e9f0f
2023-01-16 11:41:11 +00:00
Daniel Willmann 98c48a5cfa ttcn3-bsc-test: Fix ttcn3-bsc_sccplite-latest
Re-add the msc 0->mgw config line since the "latest" version of osmo-bsc still uses
it. This was probably caused by fixing fallout from osmo-bsc.git commit
da4af65a51ee8b8d7b380330c0301de293347563 in master.

The config line is ignored in master so should be safe to keep until a
new osmo-bsc version is released.

Change-Id: I85231bf66a78232567eb91b92b8542ca7f728beb
2022-11-02 19:24:17 +01:00
Pau Espin 9a330b6fc3 ttcn3-bsc: Update osmo-bsc cfg files to use mgw pooling VTY commands
OsmoBSC has supported this VTY interface since more than a year ago.
Let's update the config files to use the new "mgw" node.

The recently submitted VTY commands without the redundant "mgw" prefix
are still not used here in order to have the config file work with
latest release which still doesn't support those.

Change-Id: Iabf117f9e6de02cac16e44d9a0ca32a30d71847c
Related: SYS#5987
2022-10-19 13:50:13 +02:00
Pau Espin a719a8db61 Use gerrit as osmo-ttcn3-hacks.git git remote
Other remotes are mirrors of gerrit one, which means there's some delay
between pushing some ref to the gerrit remote and having them available
in the mirrors.
Hence, it becomes annoying while developing and new stuff to test is
pushed. Let's simply use gerrit since it's the master remote.

Change-Id: Ic87c196f8b91a3a3e6ddde2cca36482ce7070df7
2022-09-20 12:09:32 +02:00
Pau Espin bb6e5d1acb ttcn3-bsc: Enable OSMUX feature in osmo-bts-omldummy
This feature is used to indicate to the BSC that the BTS supports Osmux.

Requires: libosmocore 18c6a8183f92915e77368ecffb1cbf7f555453a3
Related: SYS#5987
Change-Id: Ia402b7514b636750442d0859d5ebc3fcad67dd9f
2022-08-30 16:00:09 +00:00
Oliver Smith 38f7fcb265 */.release: remove
These files are in .gitignore and get generated at the end of running
'make'. Remove them to have less cluttered 'git grep' output.

Change-Id: Ie5bf05220359ac0941f62cc86ed843363548784a
2022-07-06 12:36:26 +02:00
Vadim Yanitskiy 6b5d3ce269 ttcn3-bsc-test/jenkins-sccplite.sh: fix missing osmo-bts-omldummy logs
Change-Id: I823c34a754701dc71cd52df0ca660bd8fe3c02ab
2022-06-08 23:37:51 +06:00
Vadim Yanitskiy b41fcf8b4c ttcn3-bsc-test/jenkins-sccplite.sh: configure 4 TRX for BTS2
This is another fixup for [1].  I didn't notice that the sccplite
variant of ttcn3-bsc-test has its own copy of jenkins.sh.

Change-Id: I21219724adbeda4166963b4940b08aad281a62cb
Fixes: [1] Iba4fbd5c9ed59783df4ac64e68b2beef73a812ff
Related: SYS#5460
2022-06-08 23:35:52 +06:00
Vadim Yanitskiy 029594f3b2 ttcn3-bsc-test-sccplite/osmo-bsc.cfg: configure 3 additional TRX instances for BTS2
This should have been done as part of [1] in order to avoid
regressions in ttcn3-bsc-test-sccplite.

Change-Id: I2d0045533814a2bacc384c06287066f2209a5f38
Fixes: [1] Iba4fbd5c9ed59783df4ac64e68b2beef73a812ff
Related: SYS#5460
2022-06-07 16:10:04 +06:00
Vadim Yanitskiy 98183d64d7 ttcn3-bsc-test/osmo-bsc.cfg: configure 3 additional TRX instances for BTS2
Change-Id: Iba4fbd5c9ed59783df4ac64e68b2beef73a812ff
Related: Ie1241c54abac9a56906c525155cbf7482bca738e
Related: SYS#5460
2022-06-02 17:13:24 +06:00
Vadim Yanitskiy b5ecf1c3ef osmo-bsc.cfg: change logging level nm info -> notice
Stop spamming logs with tons of DNM messages (state changes, events).
GSMTAP emits all these messages (including 'debug' ones) anyway.

Related: I9e60ea0968a44aa29753226626864ac9f4c1f8ab (osmo-ttcn3-hacks.git)
Change-Id: I49352b3caf9f6bbdd594cfcdea54038fc0eaa874
2022-05-29 20:25:56 +06:00
Oliver Smith cd97dbd78b ttcn3-bsc-test: set osmo-bts-omldummy features
Add arguments to osmo-bts-omldummy to properly report the features that
were previously assumed for osmo-bts even without reporting them, until
this was changed in osmo-bsc I7fca42a39a4bc98a6ea8b9cfab28c4bad3a6a0aa.

Related: SYS#5922, OS#5538
Change-Id: Ib22f25431330676d59900de7bfb3d89e7872baf1
2022-05-03 15:10:55 +02:00
Vadim Yanitskiy 94b49e136d ttcn3-bsc-test/osmo-bsc.cfg: set AMR link adaptation params
Change-Id: Idf5b22c7d50d283d24edf5ccd8de9051f7c2642f
Related: osmo-bsc.git Ic5f8d55d250976d8d4c9cae2d89480fd52326717
Related: SYS#5917
2022-04-16 22:00:49 +03:00
Oliver Smith a0a991f412 make/Makefile: always use docker run --rm
Add --rm to the "docker run" line in make/Makefile, and remove it from
RUN_ARGS.

Related: https://osmocom.org/projects/osmocom-servers/wiki/Docker_cache_clean_up
Related: SYS#5827
Change-Id: Iea063aa39a08397ea64d2018b433991a130e7f56
2022-02-14 07:46:23 +00:00
Vadim Yanitskiy 44393058f6 make/Makefile: allow overriding '-it' for target 'run'
Allocating a pseudo-TTY (-t, --tty) fails when 'run' is executed
inside of a Jenkins or cron script.  This change fixes
ttcn3-bts-test, which invokes 'run' to fetch the config files.

Change-Id: If22f682be4f004c5bb43e65098079a4f4fe6158d
Fixes: If15461240f3037c142c176fc7da745a1701ae3f8
2022-02-11 15:21:16 +06:00
Vadim Yanitskiy bd5b02050d ttcn3-bsc-test-sccplite: set OSMO_SUT_{HOST,PORT}
This enables the test suite to obtain talloc reports between the
test case executions, which get stored together with the PCAP files.

Change-Id: I4e5474e8fc51d2ba8a0baca68e11df1346d7d4ab
2022-01-31 09:54:06 +00:00
Vadim Yanitskiy ed54b1c967 ttcn3-bsc-test/jenkins.sh: fix '--ulimit core=-1' set twice
Change-Id: I3223f8f4cc09797de44971215a94fc62ad8d263b
2022-01-26 16:43:27 +00:00
Harald Welte 0f74af6083 titan: move from debian-stetch-titan to debian-bullseye-titan
So far we were executing all our TTCN-3  tests from a container
image with Debian stretch (9) plus a custom more recent eclipse-titan
package from the osmocom feed.

Let's update the container base OS from stretch (9) to bullseye (11)
while using the same packaged eclipse-titan version (8.0.0) for running
the tests.  So this should be a low-risk change, as titan runtime
remains identical.

I've executed all test suites locally and couldn't see any regressions.

Related: OS#4969
Change-Id: Ib3bdfa3bec8f8ef42c55ca61cdee8fbca923874f
2021-12-16 11:40:17 +01:00
Harald Welte 650870c9f5 bsc-test: Reduce log verbosity of osmo-stp
I don't really see the point of crating 19 MBytes of logs for every
ttcn3-bsc-* test run that consists mainly of debug messages about
sending a message from left to right. osmo-stp is not the IUT here,
but merely a part of the test fixture.  Let's reduce log verbosity.

Change-Id: If1d22814d89c4e52b3b7804110256d896b7cc99f
2021-12-15 18:05:19 +00:00
Vadim Yanitskiy bcf017e455 ttcn3-{bts,bsc,msc,hlr}-test: set OSMO_SUT_{HOST,PORT}
This enables the test suite to obtain talloc reports between the
test case executions, which get stored together with the PCAP files.
Let's see how it works with the mentioned projects first;  others
can be configured later.  See [1] for more details.

Change-Id: Icd4c2d80db934535d499598282ed9416d8088163
Related: [1] I1b03b17426d8760c55976e3b78ca2f3af248c055
Related: OS#5328
2021-12-01 13:48:50 +00:00
Oliver Smith 305ce55b74 ttcn3: write Osmocom repository to configs
Write a line like 'Misc_Helpers.mp_osmo_repo := "nightly"' into the
TTCN-3 config file (e.g. BSC_Tests.cfg), before starting the testsuite.
This allows executing different code paths in the tests based on the
repository.

Related: OS#5327
Change-Id: Ic06532f7a67e59458652c5cf4c8f6fee8113e703
2021-11-26 18:12:50 +01:00
Pau Espin 9581a23764 ttcn3-bsc-test: Leave mp_enable_dyn_sdcch8_test enabled in latest
Release 1.8.0 is already released, so latest should support this.

Change-Id: I560cb7d0ab61b5373982160032040a65dc043ce4
2021-11-16 19:00:36 +01:00
Pau Espin ac920b7716 ttcn3-bsc: Drop mp_enable_osmux_test
This module parameter is never set to false anymore, since latest
already supports the feature for a while.
The module parameter will be removed soon in osmo-ttcn3-hacks, so let's
drop using it here too.

Change-Id: Idf459365e9aa42f7efd2a418cadea63ec49bdd7a
2021-07-20 17:02:40 +02:00
Pau Espin 14b12829fc ttcn3-bsc: Disable dyn TS SDCCH8 tests for latest
With this we'll avoid running the test in latest. This way we'll not
fail after changing the TS for the test and hence other tests won't be
affected.

Related: SYS#5309

Change-Id: If941c110501cd5f9c1d5084cc4d054e1eafb14f4
2021-07-20 16:58:07 +02:00
Oliver Smith 688cda1158 Revert "ttcn3-bsc-test: enable A5/4 support in osmo-bsc.cfg"
The test that needs A5/4 enables it dynamically, and a new test requires
a defined value to reset to.
This reverts commit 8005014b55.

Related: OS#4975
Depends: osmo-ttcn3-hacks I3cf36c6ef86a0db050507f3737f4b0c10dcd52ed
Change-Id: I55135ca00ef51de5cf6eaec75cfc20c21beef665
2021-07-09 15:10:51 +02:00
Vadim Yanitskiy 8005014b55 ttcn3-bsc-test: enable A5/4 support in osmo-bsc.cfg
Conditionally exclude it for non-master versions of the IUT.

Change-Id: I59f81c2dd72ddc2d292f8f34281fa79289d49c6d
Related: SYS#5324
2021-06-29 13:14:27 +02:00
Harald Welte 967d903040 remove deprecated 'logging level all everything' from configs
it has been deprecated in libosmocore.git 2.5 years ago:

commit 7e0686c6b4b456ec4e6e15689694b1bcf96c301f
Author: Neels Hofmeyr <neels@hofmeyr.de>
Date:   Mon Sep 10 20:58:52 2018 +0200

Change-Id: Ia6946fae497319a894d4e664ac8642340620822e
2021-04-25 13:11:03 +02:00
Vadim Yanitskiy 79b752fa32 */osmo-bsc.cfg: remove obsolete no-op parameters
Change-Id: Idebf9df98648b3fe8213cae550ce50e9805bac96
2021-03-09 13:50:41 +01:00
Pau Espin a0026cd724 ttcn3-bsc: Get rid of uneeded param BSC_Tests.mp_media_mgw_offer_ipv6
This param is true by default and there's no one setting it to false
anymore (and soon will be removed).

Related: OS#5042
Change-Id: I1780320c69ec4a9f086677fd4884dec674f8332e
2021-02-26 12:53:21 +01:00
Pau Espin bd79c36e29 Get rid of uneeded param StatsD_Checker.mp_enable_stats
This param is currently set to true by default and will be removed soon.

Related: OS#5042
Depends: osmo-ttcn3-hacks.git Change-Id I4e2049c109986906d3c985ca2282174b1abff581
Change-Id: I3c7e7dc985a339d884dc388b33bf8a6ec986c5b7
2021-02-26 12:45:20 +01:00
Oliver Smith 033c6ab1be */jenkins.sh: set -e after setting clean up trap
Abort the script and trigger the clean up script, whenever any of the
commands below to prepare the testsuite are failing. This saves time
with figuring out why suddenly all or most tests are failing, and avoids
running the entire testsuite on jenkins if it's obviously not going to
work.

Related: OS#3208
Change-Id: Ie68da2affda8c96b3a515a857a921a05f1bf8ef7
2021-02-26 09:32:34 +01:00
Oliver Smith 12b961942a jenkins-common.sh: add common clean up trap
Add set_clean_up_trap() in jenkins-common.sh and run it at the beginning
of the jenkins.sh files. Move the common clean up code from the end of
every jenkins.sh file into clean_up_common(), which gets called by the
trap. Add a custom clean_up() function to those jenkins.sh files that
need additional clean up.

Replace explicit container stop commands (for containers attached to the
docker network) with one call to network_clean() in clean_up_common(). It
kills all containers attached to the docker network.

The motivation for this change is the upcoming optional build of initrd
and kernel during ttcn3-ggsn-test/jenkins.sh. After building these, a
short smoke test will be performed to make sure we can boot the kernel
and initrd, before continuing to run the entire testsuite against it. If
building or the smoke test fails, we must do a proper clean up of the
network and fix permissions.

Related: OS#3208
Change-Id: I807c6221d22fec31db23e2516e477a3eb43347fb
2021-02-26 09:32:06 +01:00
Pau Espin c63a131a60 Remove test backward compatibility with older osmo-* versions
These changes are no longer needed since master versions of whole CNI
have been recently released.

Related: OS#5042
Change-Id: I6f491b58d4576b22c8ff3ab56a7b9e17163a8739
2021-02-25 16:41:47 +01:00
Oliver Smith 6f6724178b ttcn3: use REGISTRY arg with debian-stretch-titan
Allow jenkins to fetch the image from our private docker registry.
Outside of jenkins, the image is built locally just like before.

Related: OS#5017
Change-Id: I46cc176ea09d8badc359b627d7ce2f459211258c
2021-02-11 16:27:23 +01:00
Oliver Smith 2b38b8e779 ttcn3: move shared run code to script
While I'm at it with tidying up the Dockerfiles, create a
ttcn3-docker-run.sh with shared run code.

Related: OS#5017
Change-Id: Id90769707158f0488eca2313c57b99ea7a4a27c8
2021-02-11 15:45:40 +01:00
Oliver Smith 914a486ef1 debian-stretch-titan: prepare: start/stop links
Create symlinks to ttcn3-*-start.sh and ttcn3-*-stop.sh in the
prepare.sh script instead of in each of the ttcn3 Dockerfiles.

Related: OS#5017
Change-Id: I634cf71cff7936efe6e0461d21dc1119de922ada
2021-02-11 15:45:40 +01:00
Oliver Smith 892d910444 ttcn3: move prepare code to shared script
Move the git fetch/checkout code and make call to build the testsuite,
to debian-stretch-titan/ttcn3-docker-prepare.sh. In the next patch, I
will extend the script to update deps right before building too (e.g.
because OSMO_TTCN3_BRANCH changed).

Related: OS#5017
Change-Id: I4b5bedf058dc527e821f9b7204c632820e671af9
2021-02-11 15:45:40 +01:00
Oliver Smith 61fed0ad39 ttcn3: move initial clone to debian-stretch-titan
Clone the osmo-ttcn3-hacks and all dependency repositories less often by
moving related commands to the shared debian-stretch-titan image.

Remove the 'git checkout -f -B master origin/master' line, because the
master branch is checked out by default.

While at it, move the shared "git config" commands too, and move them
before cloning the repositories, so they don't run again whenever the
deps change (logic to invalidate the cache if deps change will be added
in the next patch).

Related: OS#5017
Change-Id: I2bb142dce061eba4b6a828c4e435510e309989fd
2021-02-11 15:45:40 +01:00
Oliver Smith db3f98113c ttcn3: remove /root/projects/git symlink
Remove leftover from old TTCN-3 build scripts, before refactoring ttcn3
Dockerfiles. This line has already been removed in 357ec806 from 2017 for
ggsn-test.

In osmo-ttcn3-hacks.git, this is only referenced in the obsolete
bin/install.script (looks like we could remove that, together with the
rest of the bin dir?).

Related: OS#5017
Change-Id: Id23e7fae58ba246916a38aa0a10035d4f67f7588
2021-02-11 15:45:40 +01:00
Neels Hofmeyr 738ec9d51f bsc: add missing 'smlc / enable' for LCS tests
This part is missing from the already merged
I3394f391a6068ab8afeafa329b69a8ae4ad05cd9
which enabled LCS tests for osmo-bsc.

Change-Id: I873d6e46e00ee0e91b15d719829baff2bf9f115a
2020-10-16 15:49:04 +02:00
Neels Hofmeyr 81f6944d15 bsc: enable LCS tests for normal bsc master tests
Change-Id: I3394f391a6068ab8afeafa329b69a8ae4ad05cd9
2020-10-15 04:11:04 +00:00