summaryrefslogtreecommitdiff
path: root/tests/topotests/munet/config.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/topotests/munet/config.py')
-rw-r--r--tests/topotests/munet/config.py13
1 files changed, 7 insertions, 6 deletions
diff --git a/tests/topotests/munet/config.py b/tests/topotests/munet/config.py
index 1b02f2e8ff..2870ae615c 100644
--- a/tests/topotests/munet/config.py
+++ b/tests/topotests/munet/config.py
@@ -191,17 +191,18 @@ class ConfigOptionsProxy:
else:
self.option = ConfigOptionsProxy.DefNoneObject()
- def getoption(self, opt, defval=None):
+ def getoption(self, opt, default=None):
if not self.config:
- return defval
+ return default
try:
- return self.config.getoption(opt, default=defval)
+ value = self.config.getoption(opt)
+ return value if value is not None else default
except ValueError:
- return defval
+ return default
- def get_option(self, opt, defval=None):
- return self.getoption(opt, defval)
+ def get_option(self, opt, default=None):
+ return self.getoption(opt, default)
def get_option_list(self, opt):
value = self.get_option(opt, "")