-
#!/usr/bin/env python
"""Basic Onboard test case."""
import logging
import time
from xtesting.core import testcase
-#from onapsdk.configuration import settings
+from onapsdk.configuration import settings
import onaptests.utils.exceptions as onap_test_exceptions
-#from onaptests.steps.onboard.service import YamlTemplateServiceOnboardStep
+from onaptests.steps.onboard.service import YamlTemplateServiceOnboardStep
class BasicOnboard(testcase.TestCase):
"""Onboard a simple VM with ONAP."""
kwargs["case_name"] = 'basic_onboard'
super(BasicOnboard, self).__init__(**kwargs)
self.__logger.debug("BasicOnboard init started")
+ self.test = YamlTemplateServiceOnboardStep(
+ cleanup=settings.CLEANUP_FLAG)
self.start_time = None
self.stop_time = None
self.result = 0
try:
self.test.execute()
self.__logger.info("VNF basic_vm successfully onboarded")
+ self.result = 100
except onap_test_exceptions.OnapTestException as exc:
self.result = 0
self.__logger.error(exc.error_message)