---
title: Using Cypress.io for automated website testing
category: Cypress
---

I was introduced to [Cypress](https://www.cypress.io/) early this year. It was light-weight, fast, and easy even for a JavaScript newbie like myself.

<!-- more -->

The tool can be run both in the terminal and in a standalone app with a pretty GUI. After looking at the examples, I managed to write executable test cases within 2 days.

It took me longer to generate test reports. I followed the suggestions from the [official documentation](https://docs.cypress.io/guides/tooling/reporters.html#Local-Reporters) and [some other articles online](https://gorillalogic.com/blog/e2e-testing-with-cypress-automation-ui-rest-api/) to use the 3rd-party tool `mochawesome`. However, one of its dependencies, `mocha`, currently has a bug that prevents version 6.0 from running normally. I had to downgrade it to version **5.2.0**.

After running `npm install --save-dev mocha@5.2.0` in the terminal, the report generator now works.

Below are the configurations I currently have in `cypress.json`.

```
{
    "video": false,
    "reporter": "mochawesome",
    "reporterOptions": {
        "overwrite": false,
        "html": true,
        "json": false,
        "timestamp": "yyyy-mm-dd'T'HH:MM:ss"
    }
}
```

Add new post on Cypress
Add new post on Cypress
