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
Currently, only failed screenshots are attached in the html report and I am looking to also add screenshots to passing scenarios. I have added an After hook to take a screenshot for passing tests and the Cypress screenshotOnFailure is default to true which will take a screenshot for failing scenarios as the After hook is skipped in failed tests. In the example, there are 2 tests in the feature file one fails and the other passes. The html report shows this as 1 FAILED and 1 SKIPPED with 0% passed. The failed test has attached images for both tests and the passing test has the correct image attached.
Desired behavior
Cucumber html report should show correct metrics for passing/failing tests along with a single attached image
ijaved
changed the title
Cucumber html report showing incorrect metrics and attached images to test
Cucumber html report showing incorrect metrics and attached images
Jun 14, 2023
Current behavior
Currently, only failed screenshots are attached in the html report and I am looking to also add screenshots to passing scenarios. I have added an
After
hook to take a screenshot for passing tests and the CypressscreenshotOnFailure
is default totrue
which will take a screenshot for failing scenarios as theAfter
hook is skipped in failed tests. In the example, there are 2 tests in the feature file one fails and the other passes. The html report shows this as1 FAILED
and1 SKIPPED
with0% passed
. The failed test has attached images for both tests and the passing test has the correct image attached.Desired behavior
Cucumber html report should show correct metrics for passing/failing tests along with a single attached image
Reproduce issue
Added example to: https://github.com/ijaved/cypress-cucumber-preprocessor-reporting-example/tree/main
Versions
Checklist
cypress-cucumber-preprocessor@4.3.1
(package name has changed and it is no longer the most recent version, see #689).The text was updated successfully, but these errors were encountered: