diff options
author | Moshe <moshehoa@amdocs.com> | 2019-01-09 09:40:40 +0200 |
---|---|---|
committer | Moshe <moshehoa@amdocs.com> | 2019-01-09 11:53:20 +0200 |
commit | ce6df7403af5694aee412836cd3c86e33307e190 (patch) | |
tree | cd9799665cba2c44e517419d4d5570f2198939ff /vnftest/contexts | |
parent | 6affd662a7793fda0be64ee103d7239702b9722b (diff) |
refactor input parameters handling
Change-Id: I599be7b0c0f9724f954fb4790dcd7d03538fdcb7
Issue-ID: VNFSDK-350
Signed-off-by: Moshe <moshehoa@amdocs.com>
fix test
Issue-ID: VNFSDK-350
Change-Id: I8f3c0b80220e88660f0a0d00c1207abd30ed2208
Signed-off-by: Moshe <moshehoa@amdocs.com>
fix test
Issue-ID: VNFSDK-350
Change-Id: Ica479453d60129ed033dfcf613dbe73bb1c60bd0
Signed-off-by: Moshe <moshehoa@amdocs.com>
fix test
Issue-ID: VNFSDK-350
Change-Id: If9470517623074708e1c602b4683a958227d16c6
Signed-off-by: Moshe <moshehoa@amdocs.com>
Diffstat (limited to 'vnftest/contexts')
-rw-r--r-- | vnftest/contexts/base.py | 20 |
1 files changed, 1 insertions, 19 deletions
diff --git a/vnftest/contexts/base.py b/vnftest/contexts/base.py index c6f3992..538a2d6 100644 --- a/vnftest/contexts/base.py +++ b/vnftest/contexts/base.py @@ -20,29 +20,11 @@ import yaml import logging LOG = logging.getLogger(__name__) + @six.add_metaclass(abc.ABCMeta) class Context(object): """Class that represents a context in the logical model""" list = [] - vnf_descriptor = {} - onap_env_config = {} - creds = {} - - @classmethod - def initialize(cls, vnf_descriptor_path, environment_path): - LOG.info('vnf descriptor path: %s', str(vnf_descriptor_path)) - LOG.info('environment path: %s', str(environment_path)) - with open(vnf_descriptor_path) as f: - cls.vnf_descriptor = yaml.safe_load(f) - with open(environment_path) as f: - environment_config = yaml.safe_load(f) - openstack_env_config = environment_config['openstack'] - openstack_utils.initialize(openstack_env_config) - cls.onap_env_config = environment_config['onap'] - - cls.creds = openstack_utils.get_credentials() - - @staticmethod def split_name(name, sep='.'): |