Commit Graph

104 Commits

Author SHA1 Message Date
Oliver Smith 5505b95a15 ttcn3-*-test: remove implicit dependencies
Don't list debian-stretch-build and debian-stretch-titan as dependencies
anymore, now that docker_images_require finds them automatically.

Related: OS#4564
Change-Id: I3cb6b693f3dd9df84fb29c0217bb3dae454cc18f
2020-05-30 09:14:06 +02:00
Vadim Yanitskiy 3bd7fc452b osmo-bsc.cfg: drop deprecated '11bit_rach_support_for_egprs'
EGPRS Packet Channel Request cannot be enabled in 'GPRS only' mode
anyway. Moreover, this command was deprecated. Let's just remove it.

Change-Id: I03733490d9c4bf78a748d22874e550e015fbab78
2020-05-29 19:23:55 +07:00
Vadim Yanitskiy 28badfaf6e osmo-bsc.cfg: drop deprecated 'ip.access rtp-base' parameter
Change-Id: Ie5494fd08fc7d2277a087ccc9502b5076fa2565b
2020-05-29 14:34:31 +07:00
Vadim Yanitskiy d210c90a68 osmo-bsc.cfg: drop non-existing 'access-list-name bsc-list'
In the recent osmo-bsc master, this configuration parameter has
been removed, so it fails to start due to "unknown parameter".

Change-Id: I8f763a4b35f80f4db637bebdd8e802a835a9fd2d
2020-05-29 14:34:31 +07:00
Vadim Yanitskiy c5f1a673bd ttcn3-bts-test: enable 3 additional transceivers for BTS#0
This is needed for the forthcoming frequency hopping test cases.

Change-Id: Ib5ad31388ae25399ad09739aac3fdcb0b3a1f78b
Depends: I86afb55ecc6703ce7a229aaa626223f9331a4778
Related: OS#4546
2020-05-28 10:31:28 +00:00
Oliver Smith f48c09d3bc ttcn3-*-test/jenkins*.sh: add $DOCKER_ARGS
Allow to pass options to each "docker run" line in the various
jenkins.sh scripts. I'm using this to run the testsuites and Osmocom
components in docker with the same configurations as jenkins, but with
Osmocom and testsuite binaries built outside and mounted into the
containers:

DOCKER_ARGS="-v /usr/local:/usr/local:ro -v $hacks:/osmo-ttcn3-hacks:ro"

This allows very short test cycles without a second set of configs. The
full script that makes use of this feature is in osmo-dev.git,
ttcn3/ttcn3.sh.

Change-Id: I8d1f78aee926f8f6ec0b704e16639bc83f525816
2020-05-06 06:22:12 +00:00
Vadim Yanitskiy bcfd877466 ttcn3-bts-test: enable time / date logging for fake_trx.py
Depends: Ie5d14a261e17af554f7132b03d58549a4831dcdb
Change-Id: I7f82e4f573db8f72256718c04bb1ace23788ba38
2020-04-14 18:00:16 +00:00
Vadim Yanitskiy b648126d15 ttcn3-bts-test/virtphy: remove deprecated 'ms-power-control dsp'
osmo-bts-virtual fails to start:

  Error occurred during reading the below line:
    ms-power-control dsp

  This BTS model has no DSP/HW MS Power Control support
  Failed to parse the config file: '/data/osmo-bts.cfg'

Change-Id: Ic85603db10c11de911d20313caf2f819e92d94d1
2020-04-05 20:14:40 +07:00
Vadim Yanitskiy 716af8e633 ttcn3-bts-test/osmo-bsc.cfg: Remove 'nat' from logging
As of Change-Id Id965295dfe04f8bd5ce831db70c86f67b8dc290b the
bogus 'NAT' log category has been removed from osmo-bsc.

Change-Id: I266d6f6ed54d1457b1ca63b87fc1c29f6dd40caf
2020-04-05 00:07:50 +07:00
Vadim Yanitskiy 76c87949db ttcn3-bts-test/oml: fix osmo-bts.cfg: osmo-bts-trx has no DSP/HW MS Power Control
It was noticed that most of the OML related TTCN-3 test cases do not
pass anymore, while some of them are green for the release builds.

The culprit is I49706926b1e962b18791174627bc3cc0cd0cd9d5, which did
not ensure backwards compatibility with older configuration files.
Let's remove 'ms-power-control dsp' and use the defaults.

Change-Id: I940df510d803d0eaa063dd5145c2f9a4c5d0543f
2019-12-19 11:15:04 +09:00
Pau Espin 1385d5e2be ttcn3-bts: Fix trxcon docker volume dir created as root
If directory is not created beforehand by the user, docker (root) will
create the directory before binding it to the container.

Related: OS#4313
Fixes: a66f6ebb23
Change-Id: I3f02faef1aa5846c48a3776191c3862bac913d10
2019-12-09 11:50:31 +01:00
Pau Espin a66f6ebb23 ttcn3-bts: Mount trxcon dir so logs can be retrieved outside of docker
Change-Id: Icd243b62b8c80cdb2c2f09e1308f00565589c0e7
2019-12-04 14:11:38 +01:00
Pau Espin c3f157b939 Update ttcn3-*/jenkins.sh to log stdout+stderr of process to log file
This way we get VTY parsing failures as well as backtraces upon process
crash.

Related: OS#4212
Change-Id: I3d9f6de638dbc07391a32c6a0cbd469dc5adf2b5
2019-11-20 17:17:45 +01:00
Pau Espin f19670453d Drop default vty cmd 'ms-power-control dsp'
That's the default value for all BTS, so no need to have it there.
Furthermore, forthcoming osmo-bts patches will drop osmo-bts-trx support
for DSP/HW based MS Power control, which means BTS will reject this
setting. Let's drop it now and let osmo-bts binary to select the
preferred one.

Related: OS#1851
Change-Id: I0f69880a5028002a53736653735c11ae3cd53f07
2019-11-14 18:40:08 +01:00
Philipp Maier e0079d37cf ttcn3-bts-test: remove obsolete vty config
The configuration file for osmo-bsc contains obsolete config statements,
which cause osmo-bsc to crash. Lets remove those config statements.

Change-Id: Ic91e2ee1e9132886cd02535bc84a568d4c25dbb4
2019-10-31 12:56:57 +01:00
Philipp Maier 80030e9815 osmo-bsc.cfg: remove obsolete logging categories (cc, mgcp)
The logging categories cc and mgcp are obsolete. The tests still contain
logging statements with those categories, which makes osmo-bsc
terminate during startup while parsing the configuration file.

Change-Id: Ifd6bf46b73420c0443f997ea953318710544b751
2019-10-30 08:08:31 +00:00
Pau Espin 65bc0ae407 ttcn-*: Fix gsmtap log not enabled
gsmtap log won't be sending any message unless it is allowed by "logging
filter all 1".

Change-Id: Ibf8062c0d962f2572a07623e6f06936df0d42c67
2019-10-04 15:50:50 +02:00
Oliver Smith c2ed5bb201 ttcn3-*: enable GSMTAP logging
Configure each osmo-* program to send GSMTAP log output to the IP of the
docker container, which runs the testsuite (and therefore runs tcpdump).

Related: https://lists.osmocom.org/pipermail/openbsc/2019-June/012946.html
Change-Id: I99e74f6ffb5b7d566cec35995bf067df414968d8
2019-07-10 09:34:39 +02:00
Harald Welte 2771b03658 ttcn3-bts-tests: Add BTS_Tests_LAPDm.control to config file
There's a number of new tests that aren't executed yet.

Change-Id: I3bfb4483f39d4dbf3f506f86470e4f2d3b6b7af2
2019-06-04 15:38:34 +00:00
Pau Espin ee49c7ba88 ttcn3-*: Enable extended-timestamp in VTY cfg
Having extended-timestamp allows for easier matching between osmo-*.log
files and pcap traces.

Change-Id: I98cdc0adc24edc966d5648d2c215c6ad7c749209
2019-06-03 17:59:42 +02:00
Harald Welte 1d60e6be3e ttcn3-bts-test: Execute OML tests without BSC
Run the testsuite one more time; this time for OML tests which
require us to run without a BSC.  We can run those with trxcon
and omso-bts-trx and don't need virtphy for them.

Related: OS#4031
Depends: osmo-ttcn3-hacks I82bb85b684d2db3a6b1e96a68ffde03e22affa6b
Change-Id: I97db9c74c56ca93c75e5e5226955799cd945eec0
2019-05-29 21:59:43 +02:00
Harald Welte da2ddb8757 ttcn3-bts-test: Add virtphy based PCUIF tests
Some tests require GPRS features not yet present in trxcon, so we have
to fall back using virtphy.

Change-Id: I2f17f03194a4dfa0abca51b0d3e22b3934d08a9a
2019-05-29 21:59:43 +02:00
Harald Welte 70c92ef1c2 ttcn3-bts-test/jenkins.sh: Move start of containers into shell functions
Change-Id: If9ac580aa5f0745468f69d413aa732891acb4a1c
2019-05-29 21:59:43 +02:00
Harald Welte 77bf937cac ttcn3-bts-test: Fix BSC VTY access from test suite
Some tests, particularly those for SMSCB, want to access the BSC
VTY.  This was enabled in the ttcn3 code, but the configs we're
using in the docker environment didn't properly refelect that yet.

Change-Id: I6b6e8b47bfe85c15fb57a25b649029f872477146
2019-05-23 17:17:31 +00:00
Oliver Smith 61f2be7bd4 Fix git checkout for branches and commits
Replace 'git checkout -f -B $BRANCH origin/$BRANCH && \' in all
Dockerfiles that accept branch variables ($OSMO_TTCN3_BRANCH,
$OSMO_MGW_BRANCH, ...) with the following:
	git checkout $BRANCH && \
	(git symbolic-ref -q HEAD && git reset --hard origin/$BRANCH || exit 1); \

This allows using branch names and commit hashes in the $BRANCH
variables. Using commits is needed for the bisect script added in [1].

The second line ("(git symbolic...") checks if we are in detached HEAD
state after the checkout, and if we are not, pulls in all new commits
from origin/$BRANCH. Note that it ends in ';' instead of '&&', because
the command in the next line should be executed even if
"git symbolic-ref" does not exit with 0 (detached HEAD state).

Here is an example, to illustrate that the new command does the right
thing. Clone a repository and be 50 commits behind origin/master:
$ git clone "https://git.osmocom.org/osmo-mgw"
$ cd osmo-mgw
$ git reset --hard origin/master~50

With BRANCH="master":
$ git checkout master && \
  (git symbolic-ref -q HEAD && git reset --hard origin/master || exit 1); \
  echo "done"
Already on 'master'
...
done
$ git status
Your branch is up-to-date with 'origin/master'.

With BRANCH="85978d":
$ git checkout 85978d && \
  (git symbolic-ref -q HEAD && git reset --hard origin/85978d || exit 1); \
  echo "done"
Note: checking out '85978d'.
...
done
$ git status
HEAD detached at 85978dad

Related previous changes:
* [2] made it work for commit hashes, but broke using branch names other
      than master, and pulling in new commits from master
* [3] made branches other than master work again, but did not fix
      pulling in new commits from master
* [4] reverted [3] and the git checkout related part from [2]

[1] Change-Id: I11f7e61a9b30d58a0fdfcaf77dde447806bf661f
[2] Change-Id: If3bc5fae07cf63c4fef68306be4c4328660bc869
[3] Change-Id: I2ff745c8d19b777d876170d5717c082ceb68a1f3
[4] Change-Id: Ie6da0f9ea96f11407e38545a6b3cf22ef9cadc25

Related: OS#4015
Change-Id: I4004980baf0b7d6096702b6f3067ccbdb369a28c
2019-05-22 11:18:56 +02:00
Harald Welte 54553bef85 osmo-bts-test: Enable BTS_Tests_SMSCB.control for CBCH testing
Support for this was introdcued in osmo-ttcn3-hacks
Change-Id If4b5a906a0841c0a8c3d7c4e9e5a3d1208ecf16a, but as we have
a separate .cfg file here, we must update it, too.

Change-Id: Iab0e9a46a8ee429619e9ef9159a631dc44ab5aeb
2019-05-21 18:33:28 +02:00
Harald Welte 06ac6e455e Revert "Simplify git checkout, allow branches and commits"
Unfortuately this commit will check out *local* master (i.e. the
previous checkout) rather than the origin/master as it's supposed to
be. This means that ever since merging this patch, our ttcn3 tests
were running some "undefined" stale versions and not current master.

This reverts commit 26565bb729.

Change-Id: Ie6da0f9ea96f11407e38545a6b3cf22ef9cadc25
2019-05-21 17:53:11 +02:00
Oliver Smith 26565bb729 Simplify git checkout, allow branches and commits
Replace the following statements:

a) "git checkout -f -B $BRANCH origin/$BRANCH"
b) "git checkout -f -B $BRANCH $BRANCH"

with:

c) "git checkout -f $BRANCH"

Regarding a), we don't need to specify 'origin/' for each branch, since
we are cloning the repositories in the same Dockerfile, and therefore we
know for sure that there is only one remote and branch names won't be
ambiguous. Removing the 'origin/' allows to put commit hashes into the
branch variables (like done in the new bisect script [1]).

Version b) does not work with branch names:
$ git checkout -f -B osmith/check-imei-before-lu osmith/check-imei-before-lu
fatal: Cannot update paths and switch to branch 'osmith/check-imei-before-lu' at the same time.
Did you intend to checkout 'osmith/check-imei-before-lu' which can not be resolved as commit?

New version c) works with both commits and branches, and it is shorter.

[1] Change-Id: I11f7e61a9b30d58a0fdfcaf77dde447806bf661f

Change-Id: I2ff745c8d19b777d876170d5717c082ceb68a1f3
2019-05-07 10:24:52 +02:00
Harald Welte 7c53c9e60d Switch all osmo-*-master and ttcn3-*-test from jessie to stretch
Jessie will be EOL in June 2019, let's make the switch to stretch
before that.

Change-Id: I37a534d07081f3d321869c86d49d03171c8da0c6
2019-03-30 09:56:36 +00:00
Harald Welte cffe1022b5 print branch name and git commit hash during docker container build
This is quite useful when looking at jenkins logs to know which exact
version was built at the time.

Change-Id: Id52c382b454e2beecf46820752aeff15b2c1a0ae
2019-03-29 16:40:40 +00:00
Max 8dea5c8a5a BTS tests: update NSVC config in osmo-bsc.cfg
* remove extra NSVC config
* use 0.0.0.0 for nsvc 0

The additional nsvc and this particular address are not used for BTS'
PCU-related tests in any way and only add confusion. It's likely a
result of copy-paste from another test.

Change-Id: Ie424107672496df70fc83c8fd6cef99a312fcee7
2019-03-21 16:03:51 +00:00
Oliver Smith 6687896c64 ttcn3-*-test: don't hardcode /usr/local/bin/
Remove hardcoded /usr/local/bin/ paths from jenkins.sh. This caused the
*-latest tests to fail, as they have the Osmocom binaries in /usr/bin
instead of /usr/local/bin.

Related: OS#3767
Change-Id: I9d1427e66028ffd15fed211b2dab5adc37718666
2019-01-28 13:58:02 +01:00
Oliver Smith 761b7acd22 ttcn3-bts-test-latest: use osmocom-bb-host-master
Do not try to run a osmocom-bb-host-latest docker image, which does not
exist as we are not tagging release versions for osmocom-bb (yet).

This was done right in the docker_images_require call at the top
already (which is why it did not try to build such a "-latest" image),
but then the script tried to use the "-latest" images anyway (instead
of hardcoding "-master").

Related: OS#3767
Change-Id: Ib743f09c71d93bf4c4ad947ef62b37de6b2d7ecc
2019-01-25 12:00:00 +01:00
Vadim Yanitskiy b6c3dd787a .../osmo-bsc.cfg: drop deprecated dyn_ts_allow_tch_f
Since Ib2335d02ea545aff837aadd49f15b2fdb418c46e, this VTY option
is deprecated in osmo-bsc, so let's actualize the config files.

Change-Id: I709e1afd2a9cccdc92eec312dff607947a10c299
2019-01-14 21:07:36 +00:00
Vadim Yanitskiy bc933e91f5 ttcn3-bts-test/jenkins.sh: use logging options of fake_trx.py
Change-Id: I32bf66b1320b752450a8cb064348b3c86b1c03cd
2019-01-14 15:40:33 +07:00
Vadim Yanitskiy 53696c67e8 BTS_Tests.cfg: use the new 'mp_bts_trxc_ip' parameter
In I7736abd85407c186856be9f1a22613a1fa6e0c32 'mp_bb_trxc_ip' was
renamed to 'mp_bts_trxc_ip'. Let's correct the config.

Depends-On: (TTCN) I7736abd85407c186856be9f1a22613a1fa6e0c32
Change-Id: I886b652ddfb1afbfcf15f99672cca1d63fd714fe
2019-01-12 07:28:17 +07:00
Pau Espin 317ca49155 bts-test: osmo-bts.cfg: Enable extended timestamp
This way messages appearing in log files can be easily matched against
pcap captures.

Change-Id: Ic59c0d7ee0d3ce71e807364d156f6e38bc0c74d1
2018-12-06 18:30:21 +01:00
Pau Espin 7a494a5ef2 ttcn3-bts-test: Log RACH requests in GSMTAP
Change-Id: Idae872492a6cf3306fb2e636c54038caa600646b
2018-11-01 14:49:23 +01:00
Oliver Smith ccf62eb231 jenkins.sh: IMAGE_SUFFIX, docker_images_require()
Default value "master" of the IMAGE_SUFFIX environment variable can be
changed to "latest" to test the latest stable builds instead of the
nightly ones. Use docker_images_require() to make sure that the required
images are existing and up-to-date before running the tests.

Related: OS#3268
Change-Id: Idbb708ab16cb71bab5069127945b63388222369e
2018-10-26 10:19:05 +02:00
Pau Espin 21831c4ef6 ttcn3-bts-test: Log fake_trx output to file
Change-Id: I82a80b045e6f298e5254f42f51dbf8c84013f45c
2018-10-25 18:05:35 +00:00
Harald Welte ff3dc6e45f ensure well-formed config files
Change-Id: Id687e63c418e2e955ccbb92f2420a80fc0704ea4
2018-09-26 09:27:38 +00:00
Oliver Smith 7ed7a2bdd2 Fix "'laforge/debian-jessie-build' not found"
Instead of hardcoding laforge's username in all FROM statements in the
Dockerfiles, make use of the USER variable (as passed through by the
"make/Makefile" with "docker build --build-arg USER=..."). Thanks to
fixeria for proposing this fix!

This requires running docker-ce, old versions of docker (such as the
one in the official repositories of the latest Fedora) don't support
variables in the FROM line. But docker-ce can be installed after
adding docker's 3rd party repositories.

Closes: OS#3457

Change-Id: Ic5f11c8a4e247f632cb6aea6d147e94c53e0130f
2018-09-06 15:17:06 +02:00
Vadim Yanitskiy fbb5366dee Rename 'osmocom-bb-trxcon' to 'osmocom-bb-host-master'
At the moment, this Docker image does contain not only trxcon,
but also FakeTRX, virt_phy, and other host applications, so
let's name it properly...

Change-Id: Ieba2411230efdedc13afcd62b8b3a2153fbaf0cb
2018-08-08 05:13:49 +07:00
Pau Espin 618505f98f ttcn3-*: Merge logfiles no matter resolution of tests
Previous to this commit, log messages were not being merged if tests
were resolved as failed (test-suite.sh ending with exit code != 0),
which can happen if at least one test failed.

Change-Id: If293fc2d3182ef2a7b997faa8b41129a9dd89c45
2018-07-06 14:50:47 +02:00
Harald Welte cf81610bd4 remove deprecated "dest" config option from config files
Change-Id: I1073846c04a8466f2ccf501e27cf152df09042c5
2018-06-03 17:11:22 +00:00
Neels Hofmeyr 2f61bf81e9 jenkins.sh: have one common function to collect logs
To remove code dup and prepare a change to where logs are written, add
collect_logs() to jenkins_common.sh and call that from each jenkins.sh after
the tests are done.

The 'rm -rf' is already done before a test starts. No need to do that again
after each test.

Change-Id: I5d8472ec36b07c828685b1bd7718e31392d168a3
2018-04-24 13:46:05 +00:00
Harald Welte 67c306a8df ttcn3-*-test: Remove cherry-pick of CCM related HACK
This is no longer needed as the fix for https://osmocom.org/issues/2718
has been merged to master of osmo-ttcn3-hacks

Change-Id: Ia0c1c134405fdbce1c65059d705827f1a643e774
Related: OS#2718
2018-04-17 21:58:08 +02:00
Vadim Yanitskiy 9d3b695d46 ttcn3-bts-test/jenkins.sh: fix fake_trx.py path
Change-Id: Ie9931651d477dc95c561a5ed554d5360b465d4da
2018-04-10 18:08:10 +07:00
Harald Welte 7bbf1c8f7c ttcn3-bts-test: Configure BTS to have dynamic PDCH
This is required by later versions of the osmo-ttcn3-hacks BTS
test suite after Change-Id I2a42531dc5555ab4772d538fda462343605b8feb

Change-Id: I229000ce7609845fdf24cafe1f5ec2bfa3f507e8
2018-04-06 13:47:34 +02:00
Neels Hofmeyr 024458ce91 ttcn3-bts-test: properly configure CTRL interface
osmo-ttcn3-hacks adds configuration of the CTRL interface in
I502b4891e6720ae2fb251c03542f707880a6f728. We need proper IP addresses here for
the f_ipa_ctrl_start() to work.

WARNING: This commit has to be merged "at the same time" as
I502b4891e6720ae2fb251c03542f707880a6f728 or the jenkins ttcn3-bts-tests will
fail.

a) if we want to set a modulepar mp_ctrl_ip here, it needs to be added to
osmo-ttcn3-hacks.

b) if we have the f_ipa_ctrl_start() in osmo-ttcn3-hacks, we need to configure
the proper IP and bind interface here, or all tests will fail because
f_ipa_ctrl_start() cannot connect.

Change-Id: I1ec86b157ebd46bf622a0ca51eba225f15c99fbb
2018-04-03 19:29:45 +02:00
Harald Welte 2f5541b134 ttcn*test: use log_merge.sh to generate per-testcase merged logs 2018-03-18 13:33:39 +00:00
Harald Welte 76e59987b3 bts-test: Change logging to file so we get BTS/BSC logs as test result 2018-03-13 13:29:23 +00:00
Harald Welte f08dadbf5f Add *.control to the [EXECUTE] statement of all ttcn3 test suites
In osmo-ttcn3-hacks, we have removed the *.control from the *.default
files, so let's add it here in the config files.  You can now change
the tests to be executed by simply editing the config here.
2018-03-13 13:26:51 +00:00
Harald Welte c0da6a0e7a Add osmo-bts-test + dependencies 2018-03-01 15:19:49 +00:00