diff options
author | Yichen Wang <yicwang@cisco.com> | 2017-08-22 12:03:14 -0700 |
---|---|---|
committer | Yichen Wang <yicwang@cisco.com> | 2017-08-22 12:04:26 -0700 |
commit | 6c4e55c53c65b7e63c17c85367b4813443c5d942 (patch) | |
tree | 23135636b516bcce7f2cb3d70053ea9de83054f3 | |
parent | 1fe5e7adb3e1d90910c18386ed64d0a787a7bf94 (diff) |
Change the signature for config validation function
Change-Id: I4ef3d18f1b068165cdfc8d08278d12ec6eac4a4c
Signed-off-by: Yichen Wang <yicwang@cisco.com>
-rw-r--r-- | nfvbench/config_plugin.py | 4 | ||||
-rw-r--r-- | nfvbench/nfvbench.py | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/nfvbench/config_plugin.py b/nfvbench/config_plugin.py index 417402a..78c2ebb 100644 --- a/nfvbench/config_plugin.py +++ b/nfvbench/config_plugin.py @@ -53,7 +53,7 @@ class ConfigPluginBase(object): """Returns RunSpec for given platform.""" @abc.abstractmethod - def validate_config(self, cfg): + def validate_config(self, cfg, openstack_spec): """Validate config file.""" @abc.abstractmethod @@ -85,7 +85,7 @@ class ConfigPlugin(ConfigPluginBase): """Returns RunSpec for given platform.""" return specs.RunSpec(self.config.no_vswitch_access, openstack_spec) - def validate_config(self, config): + def validate_config(self, config, openstack_spec): pass def prepare_results_config(self, cfg): diff --git a/nfvbench/nfvbench.py b/nfvbench/nfvbench.py index 5b94ce7..d3f7f02 100644 --- a/nfvbench/nfvbench.py +++ b/nfvbench/nfvbench.py @@ -206,7 +206,7 @@ class NFVBench(object): raise Exception('Please provide existing path for storing results in JSON file. ' 'Path used: {path}'.format(path=self.config.std_json_path)) - self.config_plugin.validate_config(self.config) + self.config_plugin.validate_config(self.config, self.specs.openstack) def parse_opts_from_cli(): |