mochawesome
mochawesome copied to clipboard
Add an option at generating report to show collapsed/folded view of all test suites
Is your feature request related to a problem? Please describe. While I also use mochawesome-merge to generate cypress reporting. I want to have a quick overview of fail/pass/skip of my tests for every scope/suite when i first open my report. Currently my report show expanded/unfolded view as standard (first load). when I currently use with Cypress for reporting, I want to be able to load the generated report.html file with first look (without a click) folded view.
Describe the solution you'd like when I currently use with Cypress for reporting, I want to be able to load the generated report.html file with first look folded view. Probably this could be a reporter option in cypress.json
Additional context
Here's an expected result i'm looking for:
Hi again, perhaps my issue should relates to https://github.com/adamgruber/mochawesome-report-generator/
I found "autoOpen" option from mochawesome-report-generator, but i don't think my request is an existing functionality. I am looking for a summarized view.
@helenou There are no current options that will do what you are requesting.
@adamgruber could this be integrated into the roadmap?
Looking at the source code I found this may be in mochawesome-report-generator : https://github.com/adamgruber/mochawesome-report-generator/blob/f1521f0999bb5bcfb9136b9a050ad84c99815b09/src/client/components/suite/suite.js
where currently the standard behaviour is to display suites expanded first load. Could this
state = {
expanded: true,
}
be set to false
via a command line. I'd prefer that option knowing I'm loading directly the resulting report.
Additionnally providing buttons "expand all" / "collapse all" would be useful too but not what i expect. I'd be happy to contribute if possible.
I tested changing that parameter gives the view I'm looking for. However I'm not advanced in React and I don't know how to make this change when running the server. As I said, keen to contribute so any lights welcome @adamgruber
hi @adamgruber could this be considered a new option to initially set to false as requested?
We do have a business case (view of report on TVs) for using the collapsed/folded view preferably.