3

I am trying to implement Mochawsome report to my Cypress 10 framework. I use cypress-mochawesome-reporter plugin and set it up regarding npm package instructions https://www.npmjs.com/package/cypress-mochawesome-reporter. But the problem is that the report is generated without imbedded screenshots despite of using embeddedScreenshots: true parameter in reporterOptions object. cypress/screenshots folder contains the necessary screenshots but they are missing in the report. Could anybody advice?

P.S. I have to add important remark. Further investigation revealed that some screenshots are imbedded, but most of them are not. On the moment of publishing this request I used only few tests to check if the plugin work at all and got a report without screenshots. Now I have a big number of tests: 81 tests total, 26 failed, and only 15 of them have screenshots. Screenshots folder contains images for all failed tests

vitaliy4us
  • 483
  • 5
  • 21

1 Answers1

0

Let me to share with you a solution I found to resolve this issue. mochawesome-reporter plugin npm package provides an example of settings need to be done in cypress.config.js. One of this setting is inlineAssets: true which is the reason of not creating assets subfolder inside cypress/reports folder. So if you remove this setting then the folder will be created and the screenshots will be attached to the report.

vitaliy4us
  • 483
  • 5
  • 21