Skip to content

Commit a9d60b1

Browse files
committed
Merge branch 'main' into fix/351
2 parents 8a48135 + 4bfab7b commit a9d60b1

File tree

4 files changed

+7336
-7541
lines changed

4 files changed

+7336
-7541
lines changed

.github/workflows/cypress-run.yml

Lines changed: 34 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -2,31 +2,37 @@ name: cypress-run
22
on: push
33
jobs:
44
cypress-run:
5-
runs-on: ubuntu-latest
6-
# Browser on which the tests are run
7-
container: cypress/browsers:node12.18.3-chrome87-ff82
8-
steps:
9-
- name: Checkout
10-
uses: actions/checkout@v2
11-
- name: Setup node
12-
uses: actions/setup-node@v1
13-
with:
14-
node-version: '12.x'
15-
- name: Install dependencies
16-
run: yarn
17-
- name: Browser tests
18-
uses: cypress-io/github-action@v2
19-
with:
20-
# Your starting script
21-
start: yarn start:test-headless
22-
# Creates and uploads GitHub artifacts in case of failure
23-
- uses: actions/upload-artifact@v1
24-
if: failure()
25-
with:
26-
name: cypress-screenshots
27-
path: cypress/screenshots
28-
- uses: actions/upload-artifact@v1
29-
if: failure()
30-
with:
31-
name: cypress-videos
32-
path: cypress/videos
5+
runs-on: ubuntu-latest
6+
# Browser on which the tests are run
7+
container: cypress/browsers:node12.18.3-chrome87-ff82
8+
steps:
9+
- name: Checkout
10+
uses: actions/checkout@v2
11+
- name: Cache dependencies
12+
uses: actions/cache@v2
13+
with:
14+
path: |
15+
./node_modules
16+
key: ${{ hashFiles('yarn.lock') }}
17+
- name: Setup node
18+
uses: actions/setup-node@v1
19+
with:
20+
node-version: "16.x"
21+
- name: Install dependencies
22+
run: yarn --dev && yarn --cwd ./playgrounds/html
23+
- name: Browser tests
24+
uses: cypress-io/github-action@v2
25+
with:
26+
# Your starting script
27+
start: yarn playground
28+
# Creates and uploads GitHub artifacts in case of failure
29+
- uses: actions/upload-artifact@v1
30+
if: failure()
31+
with:
32+
name: cypress-screenshots
33+
path: cypress/screenshots
34+
- uses: actions/upload-artifact@v2
35+
if: failure()
36+
with:
37+
name: cypress-videos
38+
path: cypress/videos

CONTRIBUTING.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,8 @@ Each PR should pass the tests and the linter to be accepted.
8181
yarn test
8282
# With auto-reload
8383
yarn test:watch
84+
# End-to-end tests
85+
yarn test:e2e
8486
# Linter
8587
yarn lint
8688
# Linter with auto-correct

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,8 @@
2222
"lint:fix": "eslint --fix .",
2323
"test": "./scripts/test",
2424
"test:watch": "./scripts/test-watch",
25-
"start:test": "concurrently --kill-others -s first \"yarn playground\" \"cypress open\"",
26-
"start:test-headless": "concurrently --kill-others -s first \"yarn playground\" \"cypress run\""
25+
"test:e2e:watch": "concurrently --kill-others -s first \"yarn playground\" \"cypress open\"",
26+
"test:e2e": "concurrently --kill-others -s first \"yarn playground\" \"cypress run\""
2727
},
2828
"files": [
2929
"dist/"

0 commit comments

Comments
 (0)