diff options
Diffstat (limited to 'src/onaptests/steps/onboard/vendor.py')
-rw-r--r-- | src/onaptests/steps/onboard/vendor.py | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/onaptests/steps/onboard/vendor.py b/src/onaptests/steps/onboard/vendor.py index b3761d2..ae93738 100644 --- a/src/onaptests/steps/onboard/vendor.py +++ b/src/onaptests/steps/onboard/vendor.py @@ -7,6 +7,10 @@ from ..base import BaseStep class VendorOnboardStep(BaseStep): """Vendor onboard step.""" + def __init__(self): + """Initialize step.""" + super().__init__(cleanup=settings.CLEANUP_FLAG) + @property def description(self) -> str: """Step description.""" @@ -17,6 +21,13 @@ class VendorOnboardStep(BaseStep): """Component name.""" return "SDC" + def check_preconditions(self, cleanup=False) -> bool: + if not super().check_preconditions(cleanup): + return False + if cleanup: + return settings.SDC_CLEANUP + return True + @BaseStep.store_state def execute(self): """Onboard vendor. |