mirror of
https://github.com/ARM-software/workload-automation.git
synced 2025-02-20 20:09:11 +00:00
ConfigurationPoint: Now validates the default value
This commit is contained in:
parent
9cc42c1879
commit
22888b502f
@ -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
|
||||
|
Loading…
x
Reference in New Issue
Block a user