LironEr / cypress-mochawesome-reporter

Zero config Mochawesome reporter for Cypress with screenshots and videos
MIT License
159 stars 49 forks source link

Single report for cypress parallelisation #139

Closed Gayathri-Kesavakannan closed 9 months ago

Gayathri-Kesavakannan commented 1 year ago

Hi I need help for reporter. My repo has 1000 tests , so we use parallization and tagging in Jenkins with 4 tags I use cypress-multi-reporters and cypress-mochawesome-reporter. At the end of Jenkins build, 4 reports are generated ( html and mocha.json ) and saved in nexus.

I can configure to have 4 emails of nexus link.

I want to merge only stats of each tag and get only 1 email , is it possible ?

Is it possible to extract only stats from all tag mochaawesome.json reports and email (1 email for all 4 tags)

Something like this

Build #jobnumber Jenkins link for build

@tag1 suites Tests Passing Failing pending skipped

        1. 3

@tag2 suites Tests Passing Failing pending skipped 30 40 35 3

Thanks Gayathri

stale[bot] commented 1 year ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions.

LironEr commented 1 year ago

Will it help if this reporter will export a function or a CLI command that merges multiple JSONs and creates a final HTML report?

TzolkinB commented 1 year ago

Yes, this plugin has great customizable options I want to take advantage of but need it to support running tests in parallel in CI.

LironEr commented 1 year ago

Check out the setup guide for cypress-parallel https://github.com/LironEr/cypress-mochawesome-reporter/tree/master/examples/cypress-parallel

If you dont use cypress-parallel you can still use the cli command, should help with what you need

npx generate-mochawesome-report
ngandymovpr commented 10 months ago

Hey @LironEr can u pls explain how I can fix my issue with npx generate-mochawesome-report I set-up all steps from (https://github.com/LironEr/cypress-mochawesome-reporter/tree/master/examples/cypress-parallel) But get error

read config from cypress/.tmp/cypressMochawesomeReporterConfig.json
node:internal/process/promises:288
            triggerUncaughtException(err, true /* fromPromise */);
            ^
LironEr commented 9 months ago

@ngandymovpr Please create a repo with the problem and steps to reproduce the issue so I can have a look.

Thanks.

chilkakalpesh commented 4 months ago

Hey @LironEr can u pls explain how I can fix my issue with npx generate-mochawesome-report I set-up all steps from (https://github.com/LironEr/cypress-mochawesome-reporter/tree/master/examples/cypress-parallel) But get error

read config from cypress/.tmp/cypressMochawesomeReporterConfig.json
node:internal/process/promises:288
            triggerUncaughtException(err, true /* fromPromise */);
            ^

@ngandymovpr Did you got any fix for this? Or any alternative way. Please let me know, since I'm also facing similar issue and created issue under same repo - https://github.com/LironEr/cypress-mochawesome-reporter/issues/196

ngandymovpr commented 4 months ago

@ngandymovpr Did you got any fix for this? Or any alternative way. Please let me know, since I'm also facing similar issue and created issue under same repo - #196

@chilkakalpesh Hey, Yes, Im using https://www.npmjs.com/package/concurrently Start tests from command: "test:parallel": "concurrently --names 'GROUP1,GROUP2' --prefix-colors 'yellow,blue' 'npm run test:suite cypress/e2e/group1/' 'node -e \"setTimeout(()=>{}, 5000)\" && npm run test:suite cypress/e2e/group2/'" And after run need generate one report: generate-mochawesome-report