ploigos-step-runner
ploigos-step-runner copied to clipboard
Replace 'assert' with 'raise' for Maven logic
For consistency, as well as the ability to control the Exception thrown which validations fail within our logic, replace 'assert' statements with 'raise' statements, e.g.,
assert os.path.exists(pom_file_path), \
f'Given maven pom file (pom-file) does not exist: {pom_file_path}'
becomes
if not os.path.exists(pom_file_path):
raise StepRunnerException(
f'Given maven pom file (pom-file) does not exist: {pom_file_path}'
)