1
0
mirror of https://github.com/ARM-software/workload-automation.git synced 2024-10-06 10:51:13 +01:00

ConfigurationPoint: Now validates the default value

This commit is contained in:
Sebastian Goscik 2016-08-12 13:58:51 +01:00
parent 9cc42c1879
commit 22888b502f

View File

@ -222,6 +222,12 @@ class ConfigurationPoint(object):
self.merge = merge
self.aliases = aliases or []
if self.default is not None:
try:
self.validate_value("init", self.default)
except ConfigError:
raise ValueError('Default value "{}" is not valid'.format(self.default))
def match(self, name):
if name == self.name:
return True