Skip to content

Improve SelenideAddons.wrapAssertionError #142

@oomelianchuk

Description

@oomelianchuk

The aim of the SelenideAddons.wrapAssertionError is to make JUnit assertion to be alike the Selenide assertions. This is currently not completely fulfilled, as Selenide assertions supply the Allure report with a screenshot and code snippet, which causes the failure (as you can see in this report), but the wrapped assertions only take a screenshot (example).

This wouldn't be such a problem if the error message from after hook didn't overwrite the one from the test. Such a report with selenide assertion even if makes it a bit more difficult to figure out the failure reason by not supplying the stack trace, but at least leaves some hints in form of code snippet in the step annotation. The wrapped assertion instead doesn't have any own step annotation, which makes it difficult to figure out the failure reason, especially if the assertion was made about something, which doesn't have an impact on the currently opened page (makes screenshot irrelevant)

Please improve the SelenideAddons.wrapAssertionError method by making it to add the failure message to the Allure report. The method could be even better if the stack trace could also be attached to the Allure report, so if there is an option to do it, please also add this functionality.

Metadata

Metadata

Assignees

Labels

High PrioritybugcodeDoneThe issue is rechecked for development branchcodeReadyForRecheckThe issue is fixed/implemented AND merged into development, but needs to be rechecked there

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions