resource: ipa_unit_id is expected to be a positive integer
Change-Id: I26d7a4351089b73716d193496d7161bf3d9988bb
diff --git a/src/osmo_gsm_tester/schema.py b/src/osmo_gsm_tester/schema.py
index 2da80cd..b904960 100644
--- a/src/osmo_gsm_tester/schema.py
+++ b/src/osmo_gsm_tester/schema.py
@@ -66,8 +66,14 @@
return
raise ValueError('Unknown Authentication Algorithm: %r' % val)
+def uint(val):
+ n = int(val)
+ if n < 0:
+ raise ValueError('Positive value expected instead of %d' % n)
+
INT = 'int'
STR = 'str'
+UINT = 'uint'
BOOL_STR = 'bool_str'
BAND = 'band'
IPV4 = 'ipv4'
@@ -79,6 +85,7 @@
SCHEMA_TYPES = {
INT: int,
STR: str,
+ UINT: uint,
BOOL_STR: str2bool,
BAND: band,
IPV4: ipv4,