Skip to content
This repository was archived by the owner on Mar 5, 2022. It is now read-only.

Commit a84de0e

Browse files
committed
feat: add simple support file load
1 parent 62ae45e commit a84de0e

File tree

3 files changed

+8
-2
lines changed

3 files changed

+8
-2
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,8 @@ If you are using Create-React-App v3, and want to reuse the built in webpack bef
152152

153153
```json
154154
{
155-
"pluginsFile": "node_modules/cypress-react-unit-test/plugins/cra-v3"
155+
"pluginsFile": "node_modules/cypress-react-unit-test/plugins/cra-v3",
156+
"supportFile": "node_modules/cypress-react-unit-test/support"
156157
}
157158
```
158159

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@
1818
"files": [
1919
"dist",
2020
"lib",
21-
"plugins"
21+
"plugins",
22+
"support"
2223
],
2324
"types": "lib",
2425
"keywords": [

support/index.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
// should be loaded from cypress.json as a support file
2+
// "supportFile": "node_modules/cypress-react-unit-test/support"
3+
// adds commands from cypress-react-unit-test
4+
require('cypress-react-unit-test')

0 commit comments

Comments
 (0)