-
Notifications
You must be signed in to change notification settings - Fork 98
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
JUnit5: failed assumptions are handled like failed test cases in JGiven reports #1625
Comments
@mtthsAtrv sorry for the slow progress. I have been swamped and did not yet find the time to look deeper into the matter |
Hi @l-1squared , thanks for the information :-) Might I ask you if you already have a raw guess when a solution might be available for this issue? Thanks a lot |
I will devote as much time to this as possible. The first thing I want to do is write some JGiven tests so that we have an end-to-end view on failing assumptions. I now want to eradicate this issue once and for all. |
Thanks a lot for your feedback @l-1squared :-) We are looking forward to the solution ... |
At least I now managed to reproduce the issue :) |
Hi, I think I by now drilled down to the actual issue, and thankfully you have already provided me with a pointer. Because in my current setup. If I fail for the first step, I will completely omit that the scenario existed (which also doesn't sound quite right) whereas for JUnit5 I don't. |
Ah, so I think I've figured it out. But, it appears as if previously, failed assumpitons would have just omitted the scenarios from the report. This does not sit quite right with me so I'm trying to make them behave like failing scenarios, but they will show up with a grey marker. |
I think that would be fine for us, but could you please - in addition to using another colour - also replace the word "failed" by "skipped" or another description that is consistent with JUnit (surefire) test reports? Currently ist looks like and the word "failed" seems not be quite right on failed assumptions. |
The plan right now is to introduce a new Step and Scenario status called "ABORTED" that will show up in grey like pending scenarios but will in its behavior be more akin to "failed" scenarios. |
Thanks a lot for your feedback - that sounds good to us. Could you please let us know as soon as a (preview) version is available? |
Hi l-1squared, I wanted to ask if maybe you could already give us a prediction when the JGiven version fixing this issue might be available? Would be great, because we could need this information for our Sprint plannings ... Kind regards |
HI @mtthsAtrv as much as I would like to give you a date for this. I cannot. The time I can devote to this project depends on a multitude of factors that are in combination hard to obtain estimates from. |
Hi @l-1squared , thanks a lot for this information. So we'll sadly have to come to terms with that effect for the next time. We'll keep watching this issue and are looking forward to a solution ... Kind regards |
Hi,
if we execute JGiven tests under JUnit5 and an assumption fails, this is still treated like the test case failed because of an exception.
There was a fix that has been delivered for #1465 , but we still observe that effect, even with JGiven version 1.3.1.
After debugging this we observed that method JGivenExtension#afterTestExecution(ExtensionContext) treats all Exceptions the same way and makes no difference whether there was a exception caused by assumptions or other reasons.
Also see similar Issue #185 for Junit 4.
The text was updated successfully, but these errors were encountered: