diff options
-rw-r--r-- | test/config.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/test/config.py b/test/config.py index 511c3c6ae09..2fa93ddef3b 100644 --- a/test/config.py +++ b/test/config.py @@ -7,7 +7,7 @@ from vpp_qemu_utils import can_create_namespaces def positive_int_or_default(default): def positive_integer(v): - if v is None or v == "": + if v is None or v == "" or int(v) == default: return default if int(v) <= 0: raise ValueError("value must be positive") @@ -18,7 +18,7 @@ def positive_int_or_default(default): def positive_float_or_default(default): def positive_float(v): - if v is None or v == "": + if v is None or v == "" or float(v) == default: return default if float(v) <= 0: raise ValueError("value must be positive") |