Skip to content
This repository has been archived by the owner on May 24, 2021. It is now read-only.

Commit

Permalink
chore(docs): Add usage - Set environment variable in cypress.json (#33)
Browse files Browse the repository at this point in the history
* Add usage: Set "env" in cypress.json
  • Loading branch information
clarmso authored and kuceb committed Nov 17, 2019
1 parent 1f9088f commit a25cf65
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,15 @@ CYPRESS_RETRIES=2 npm run cypress
```js
Cypress.env('RETRIES', 2)
```
**or** Set the `"env"` key in your `cypress.json` configuration file to set the retry number for **all tests**:
```json
{
"env":
{
"retries": 2
}
}
```
**or** On a per-test or per-hook basis, set the retry number:
> Note: this plugin **adds Cypress.currentTest** and you should only access it in the context of this plugin.
```js
Expand Down

0 comments on commit a25cf65

Please sign in to comment.