In scripted pipeline the use of try/catch/finaly allows a stage to be executed even though the previous stage has failed, let say unit tests, checkstyles have failed and we still want to execute a sonaqube analysis (why would we want to do that is another question for another group).
In the declarative pipeline model however if the testing stages is executed and it turns out that some tests have failed the next stage is skipped. I was wondering if there is a way to that in declarative pipeline?
The only thing i see is worth exploring is making sure the sh command that execute the tests steps doesn't return an exit code that is a non zero, which should allow the test to continue but i am wondering if jenkins will still report a failed build?
Omeka