Logo
BlogToast.
HomeAll PostsCategoriesRandom
Sign in
Logo
BlogToast.

Discover stories, insights, and perspectives from writers around the world.

Explore

  • All posts
  • Categories
  • Random

Dashboard

  • Sign in
  • Sign up
  • Forgot password

Legal

  • Contact
  • Privacy policy
  • Terms of service

© 2026 BlogToast. All rights reserved.

Cypress: Generate reports of automated tests
Education2 min read

Cypress: Generate reports of automated tests

N

N@rutO

October 30, 2024

This is the detailed guide to generate test results of automation testing using cypress. Before introduction of cypress cloud, one of the tedious tasks for automation testing was to generate reports of testing. This problem was overcome by using cypress cloud, where a team can simultaneously view reports and results of system being tested. But it is not free. If you want an alternative, a small report of tests can be generated by using mochawesome.

It is a package for cypress to generate test report. Follow these steps:

  1. Install necessary packages.

    npm i mochawesome mochawesome-merge mochawesome-report-generator
  2. In cypress config, import merge and generator.

    const { merge } = require("mochawesome-merge");
    const generator = require("mochawesome-report-generator");
  3. In config export add these options

    reporter: "mochawesome",
      reporterOptions: {
        overwrite: false,
        html: true,
        json: true,
        reportDir: "cypress/reports/mochawesome",
      },
  4. Now run all tests and see if report is generated. It will be stored in above mentioned folder.

    npx cypress run
  5. Report can be accessed in html or json format. Open reports folder and open the main html file in a browser.

Tags

cypress report mochawesome
Advertisement

Discussion (0)

Related Blogs

Explore similar articles

What to do immediately after database update in laravel?
Education
3 min

What to do immediately after database update in laravel?

J

N@rutO

Aug 14

2 0
Setup environment variables in cypress: A comprehensive guide.
Education
2 min

Setup environment variables in cypress: A comprehensive guide.

J

N@rutO

Sep 18

0 0