-
-
Notifications
You must be signed in to change notification settings - Fork 467
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Exceptions in Context should fail all tests in scope #79
Comments
Interesting scenario, thanks for creating an issue on this. Will look at it in the near future. |
I agree with this. |
In terms of implementation, it would be much easier to output one message and then ignore the rest of the current What would be the value of having all of the tests that weren't executed in the output? If it's worth the development effort, then it could certainly be done. Also, what would be the proper behavior if an error occurs in a |
For CI jobs it would be handy if Pester could exit with a non-zero exit code if an exception is thrown from a Context (assuming it was invoked with -EnableExit). Currently it exits with code 0 as long as all tests that could run have passed. Counting the exact number of skipped tests is probably less important than reporting that there were errors. Just for reference I looked into what JUnit does when a |
That should be pretty easy to do. I'll look into it this week. |
Just opened a very basic PR to accomplish this, to give us something concrete to talk about. There may be improvements to be made here. (For instance, the code that parses |
Merged the PR which turns a terminating error in a |
If I have some code in the
Context
for setup purposes that fails, it would be great if the project would consider one of the two strategies below:It
assertion/test with the same exception.Thoughts?
Example:
The text was updated successfully, but these errors were encountered: