Commit Graph

14 Commits

Author SHA1 Message Date
Harald Welte 2720534f27 Re-License under GPLv3-or-later instead of AGPLv3-or-later
The "Affero" nature makes sense for the Osmocom network components like
BSC, SGSN, etc. as they are typically operated to provide a network
service.

For testing, this doesn't make so much sense as it is difficult to
imagine people creating a business out of offering to run test cases on
an end-to-end Osmocom GSM network.  So let's drop the 'Affero' here.

All code is so far developed by sysmocom staff, so as Managing Director
of sysmocom I can effect such a license change unilaterally.

Change-Id: I8959c2d605854ffdc21cb29c0fe0e715685c4c05
2017-06-03 14:23:51 +00:00
Neels Hofmeyr ed4e528693 fix: free resources when a suite run is done
Add missing code to free resources, not upon program exit, but when a suite is
done.

This allows running more than one suite in a row.

Also add a check to not attempt to free if there is nothing to be freed, to
avoid a regression test failure triggered when a suite exits without reserving
anything.

Change-Id: Ic017a1cf07052f5e48812c8553fba6f972d280f0
Related: OS#2301
2017-05-29 03:03:39 +02:00
Neels Hofmeyr 2a1a1fa8f9 fix: None error on unavailable resources
If not a single resource of a wanted item was left, we ran into a None. Report
unavailability instead.

Change-Id: Ie1849a74cb227964e7c3ac06852582baa2333697
2017-05-29 02:54:41 +02:00
Neels Hofmeyr 76d8103bfb rename resource nitb_iface to ip_address
I would like to use the IP addresses also for OsmoBSC processes, so it is more
than clear now that 'nitb_iface' was the wrong naming choice.

The only distinction we may need in the future is public versus loopback
interface. To add that, we may add a trait to the 'ip_address' resource
like:

  ip_address:
  - addr: 10.42.42.1
    type: public
  - addr: 127.0.0.1
    type: loopback

This way we can substitute public vs loopback addresses flexibly (e.g. using
scenarios).

Change-Id: I3ad583ae7a33f7a7bb56fe78a125f73c56a0e860
2017-05-29 00:18:43 +02:00
Neels Hofmeyr 2d1d561eeb resource error logging that is easier to understand
Log what a suite requested, what it has reserved and the complete resource
state.

Change-Id: Ic6887bbe5fe74a73f0e344cd4078dd7ed989cc15
2017-05-29 00:18:42 +02:00
Neels Hofmeyr 391afe3b13 remove bts_ocpthy.py
We're not currently paying attention to the octphy in osmo-gsm-tester. So
instead of maintaining dead code, remove the bts_octphy.py; we can re-add when
the octphy is implemented properly.

Change-Id: Ia5d5750d440ae7019634b51fa1efe7bbb2a1d1e2
2017-05-25 04:09:20 +02:00
Neels Hofmeyr cccbe5987d improve logging for resource allocation
Log on level 'log', more clearly show whether it's for reservation or actual
use, show the origin that is asking for them.

Change-Id: I3b78c7bdcaec90943900343c878099160f8d2f64
2017-05-08 12:50:42 +02:00
Neels Hofmeyr 9b90770716 Resource.find: allow returning empty instead of raising
Add flag raise_if_missing, and if False, instead of raising an exception,
return an empty list for that kind of resource. This makes sense for a caller
that requests a single resource.

When finding a single resource to use in ReservedResources.get(), use this to
raise a more adequate exception message if none was found.

Change-Id: Ia296ea68a787bede037a6cea38563b570fb0766e
2017-05-08 10:11:52 +00:00
Neels Hofmeyr 2fade33e49 doc: Resources.find: add API doc + inline comments
Change-Id: Ib6376794e28f8faff82517af99dfb38ab4689ac8
2017-05-08 10:11:51 +00:00
Neels Hofmeyr f1a9029514 fix resources: msisdn must not be too short, start with 1000 2017-05-02 16:31:15 +02:00
Your Name 44af3415a5 fix octphy, fix conf, improve logging
Clearly separate the kinds of BTS hardware the GSM tester knows ('type') from
the NITB's bts/type config item ('osmobsc_bts_type' -- not 'osmonitb_...' to
stay in tune with future developments: it is the libbsc that needs this).

For BTS hardware kinds, use the full name of the binary for osmo driven models:
osmo-bts-sysmo, osmo-bts-trx, osmo-bts-octphy.

Change-Id: I1aa9b48e74013a93f9db1a34730f17717fb3b36c
2017-04-13 03:39:07 +02:00
Neels Hofmeyr 17c139ef4c octphy (untested); fix regression test expectations
Change-Id: Ie9986e0fe49171fb616ce92c3d8652002318f94f
2017-04-12 03:13:03 +02:00
Neels Hofmeyr 3531a192ae core implementation
code bomb implementing the bulk of the osmo-gsm-tester

Change-Id: I53610becbf643ed51b90cfd9debc6992fe211ec9
2017-04-08 15:43:19 +02:00
Neels Hofmeyr dae3d3c479 initial import
The original osmo-gsm-tester was an internal development at sysmocom, mostly by
D. Laszlo Sitzer <dlsitzer@sysmocom.de>, of which this public osmo-gsm-tester
is a refactoring / rewrite.

This imports an early state of the refactoring and is not functional yet. Bits
from the earlier osmo-gsm-tester will be added as needed. The earlier commit
history is not imported.
2017-03-28 12:37:17 +02:00