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

Commit 6dc2138

Browse files
authored
Move more example dependencies (#499)
1 parent 4eeb9c4 commit 6dc2138

File tree

7 files changed

+84
-1664
lines changed

7 files changed

+84
-1664
lines changed

circle.yml

Lines changed: 39 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -58,8 +58,14 @@ workflows:
5858
requires:
5959
- Component Tests
6060
executor: cypress/base-12
61-
# each example installs "cypress-react-unit-test" as a local dependency (symlink)
62-
install-command: npm install --no-bin-links
61+
install-command: |
62+
ls -la ../..
63+
echo ***Installing cypress-react-unit-test from root TGZ archive***
64+
npm install -D ../../cypress-react-unit-test-0.0.0-development.tgz
65+
echo ***Installing other dependencies***
66+
npm install
67+
echo ***rename root node_modules to avoid accidental dependencies***
68+
mv ../../node_modules ../../no_modules
6369
verify-command: echo 'Already verified'
6470
no-workspace: false
6571
working_directory: examples/using-babel
@@ -71,8 +77,14 @@ workflows:
7177
requires:
7278
- Component Tests
7379
executor: cypress/base-12
74-
# each example installs "cypress-react-unit-test" as a local dependency (symlink)
75-
install-command: npm install --no-bin-links
80+
install-command: |
81+
ls -la ../..
82+
echo ***Installing cypress-react-unit-test from root TGZ archive***
83+
npm install -D ../../cypress-react-unit-test-0.0.0-development.tgz
84+
echo ***Installing other dependencies***
85+
npm install
86+
echo ***rename root node_modules to avoid accidental dependencies***
87+
mv ../../node_modules ../../no_modules
7688
verify-command: echo 'Already verified'
7789
no-workspace: true
7890
working_directory: examples/using-babel-typescript
@@ -316,21 +328,40 @@ workflows:
316328
requires:
317329
- Component Tests
318330
executor: cypress/base-12
319-
# each example installs "cypress-react-unit-test" as a local dependency (symlink)
320-
install-command: npm install --no-bin-links
331+
install-command: |
332+
ls -la ../..
333+
echo ***Installing cypress-react-unit-test from root TGZ archive***
334+
npm install -D ../../cypress-react-unit-test-0.0.0-development.tgz
335+
echo ***Installing other dependencies***
336+
npm install
337+
echo ***rename root node_modules to avoid accidental dependencies***
338+
mv ../../node_modules ../../no_modules
321339
verify-command: echo 'Already verified'
322340
no-workspace: true
323341
working_directory: examples/snapshots
324342
command: npm test
325343
store_artifacts: true
344+
post-steps:
345+
- run:
346+
name: Check coverage 📈
347+
command: |
348+
npm run check-coverage
349+
npm run only-covered
350+
working_directory: examples/snapshots
326351

327352
- cypress/run:
328353
name: Visual Sudoku
329354
executor: cypress/base-12
330355
requires:
331356
- Component Tests
332-
# each example installs "cypress-react-unit-test" as a local dependency (symlink)
333-
install-command: npm install --no-bin-links
357+
install-command: |
358+
ls -la ../..
359+
echo ***Installing cypress-react-unit-test from root TGZ archive***
360+
npm install -D ../../cypress-react-unit-test-0.0.0-development.tgz
361+
echo ***Installing other dependencies***
362+
npm install
363+
echo ***rename root node_modules to avoid accidental dependencies***
364+
mv ../../node_modules ../../no_modules
334365
verify-command: echo 'Already verified'
335366
no-workspace: true
336367
working_directory: examples/visual-sudoku

examples/snapshots/package.json

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,18 @@
33
"description": "Component testing with snapshots",
44
"private": true,
55
"scripts": {
6-
"test": "../../node_modules/.bin/cypress run",
7-
"cy:open": "../../node_modules/.bin/cypress open",
8-
"check-coverage": "../../node_modules/.bin/check-coverage src/App.js",
9-
"only-covered": "../../node_modules/.bin/only-covered src/App.js"
6+
"test": "cypress run",
7+
"cy:open": "cypress open",
8+
"check-coverage": "check-coverage component/PositiveCounter.js",
9+
"only-covered": "only-covered component/PositiveCounter.js"
1010
},
1111
"devDependencies": {
12-
"cypress-react-unit-test": "file:../.."
12+
"check-code-coverage": "1.10.0",
13+
"cypress": "5.3.0",
14+
"cypress-react-unit-test": "file:../..",
15+
"react": "^16.13.1",
16+
"react-dom": "^16.13.1",
17+
"react-scripts": "3.4.1",
18+
"cypress-plugin-snapshots": "1.4.4"
1319
}
1420
}

examples/using-babel-typescript/package.json

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,17 @@
33
"description": "Component testing for TypeScript projects using Babel config",
44
"private": true,
55
"scripts": {
6-
"test": "../../node_modules/.bin/cypress-expect run --min-passing 1",
7-
"cy:open": "../../node_modules/.bin/cypress open"
6+
"test": "cypress-expect run --min-passing 1",
7+
"cy:open": "cypress open"
88
},
99
"devDependencies": {
10-
"cypress-react-unit-test": "file:../.."
10+
"@babel/preset-typescript": "7.12.1",
11+
"babel-loader": "8.1.0",
12+
"cypress": "5.4.0",
13+
"cypress-expect": "2.1.2",
14+
"cypress-react-unit-test": "file:../..",
15+
"react": "^16.13.1",
16+
"react-dom": "^16.13.1",
17+
"webpack": "4.44.2"
1118
}
1219
}

examples/using-babel/package.json

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,19 @@
33
"description": "Component testing for projects using Babel config",
44
"private": true,
55
"scripts": {
6-
"test": "../../node_modules/.bin/cypress-expect run --min-passing 17",
7-
"cy:open": "../../node_modules/.bin/cypress open"
6+
"test": "cypress-expect run --min-passing 17",
7+
"cy:open": "cypress open"
88
},
99
"devDependencies": {
10-
"cypress-react-unit-test": "file:../.."
10+
"babel-loader": "8.1.0",
11+
"cypress": "5.4.0",
12+
"cypress-expect": "2.1.2",
13+
"cypress-react-unit-test": "file:../..",
14+
"react": "^16.13.1",
15+
"react-dom": "^16.13.1",
16+
"webpack": "4.44.2"
17+
},
18+
"dependencies": {
19+
"react-loading-skeleton": "2.1.1"
1120
}
1221
}

examples/visual-sudoku/package.json

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,19 @@
66
"homepage": "https://raravi.github.io/sudoku",
77
"license": "MIT",
88
"devDependencies": {
9-
"cypress-react-unit-test": "file:../.."
9+
"cypress": "5.3.0",
10+
"cypress-react-unit-test": "file:../..",
11+
"react": "^16.13.1",
12+
"react-dom": "^16.13.1",
13+
"react-scripts": "3.4.1",
14+
"cypress-image-snapshot": "3.1.1"
1015
},
1116
"scripts": {
1217
"start": "react-scripts start",
1318
"build": "react-scripts build",
1419
"eject": "react-scripts eject",
15-
"test": "../../node_modules/.bin/cypress run",
16-
"cy:open": "../../node_modules/.bin/cypress open",
20+
"test": "cypress run",
21+
"cy:open": "cypress open",
1722
"docker:run": "docker run -it -v $PWD/../..:/e2e -w /e2e/examples/visual-sudoku cypress/included:4.5.0"
1823
},
1924
"eslintConfig": {

0 commit comments

Comments
 (0)