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
The bug has been reported for integration I work on. When common exception is thrown from test, tests are considered PASSED by net.serenitybdd.junit5.SerenityTestExecutionListener#testFinished.
What did you expect to happen?
Both tests status should be updated to FAILED by net.serenitybdd.junit5.SerenityTestExecutionListener#testFinished.
Work on this myself and propose a PR (with Serenity BDD team guidance)
Note
I made some digging here. It appeared the issue is with lines 357-359 of net.serenitybdd.junit5.SerenityTestExecutionListener#testFinished: if clause appears to be false in those 2 cases.
This chain leads to result.isLessSevereThan and result.isMoreSevereThan not seeming to work as expected by its naming (they're currently opposite). The reason is that those methods use ordinal() to compare enum values, however, values are ordered not in expected state for it to work correctly.
The text was updated successfully, but these errors were encountered:
What happened?
The bug has been reported for integration I work on. When common exception is thrown from test, tests are considered PASSED by
net.serenitybdd.junit5.SerenityTestExecutionListener#testFinished
.What did you expect to happen?
Both tests status should be updated to FAILED by
net.serenitybdd.junit5.SerenityTestExecutionListener#testFinished
.Serenity BDD version
2.3.4, 4.0.8
JDK version
11
Execution environment
No response
How to reproduce the bug.
How can we make it happen?
Work on this myself and propose a PR (with Serenity BDD team guidance)
Note
I made some digging here. It appeared the issue is with lines 357-359 of
net.serenitybdd.junit5.SerenityTestExecutionListener#testFinished
:if
clause appears to befalse
in those 2 cases.This chain leads to
result.isLessSevereThan
andresult.isMoreSevereThan
not seeming to work as expected by its naming (they're currently opposite). The reason is that those methods useordinal()
to compare enum values, however, values are ordered not in expected state for it to work correctly.The text was updated successfully, but these errors were encountered: