You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In PR #638 several issues were noted, this issue should address them.
Summary:
We could even assert on the step structure here via this.context.getCurrentStep().
In StepImpl we could expose getChildren() for testing.
Just a thought since here we do not assert the status of aggregated steps nor the overall success or failure.
Also by thinking this further and just by reading the code I am now confident that there is an error and this will not work:
First of all the overall status should not be success but error and we should get exit code != 0 in such case.
My assumption is even that we will fail with an assertion error if we succeed the root step if it has child steps that are not successful but I have not verified this. At least my expectation is that a step should only be successful if all its child steps are successful.
This is all not your fault and your PR and changes are great. It is just that this review reveals new related problems that I now get aware of. IMHO we should also fix that together. But if you want you can also create a new bug issue and merge this first...
Make sure that if a parent step has child steps which failed, the overall parent step will fail too.
The parent step should only succeed if all child steps were successful.
Make success() return a boolean instead of void.
Replace the return of ProcessResult.SUCCESS with a conditional on the boolean result of success()
We need to create a new test project for this case e.g. install some tools successfully, fail one in between and install more tools successfully and assert the exit code of the overall result.
The text was updated successfully, but these errors were encountered:
In PR #638 several issues were noted, this issue should address them.
Summary:
Hints
Make sure that if a parent step has child steps which failed, the overall parent step will fail too.
The parent step should only succeed if all child steps were successful.
Make
success()
return a boolean instead of void.Replace the return of
ProcessResult.SUCCESS
with a conditional on the boolean result of success()We need to create a new test project for this case e.g. install some tools successfully, fail one in between and install more tools successfully and assert the exit code of the overall result.
The text was updated successfully, but these errors were encountered: