Skip to content

Commit

Permalink
Add dependency caching
Browse files Browse the repository at this point in the history
  • Loading branch information
Stuk committed Oct 11, 2021
1 parent 5ee321e commit 40cc7f4
Showing 1 changed file with 19 additions and 2 deletions.
21 changes: 19 additions & 2 deletions .github/workflows/pr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,34 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- uses: actions/setup-node@v2
with:
node-version: 'lts/*'
cache: 'npm'
- run: npm install

- name: Cache Node modules
uses: actions/cache@v2
env:
cache-name: cache-node-modules
with:
# npm cache files are stored in `~/.npm` on Linux/macOS
path: ~/.npm
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
- name: "Install dependencies"
run: |
npm install
sudo npx playwright install-deps
- name: Lint
run: npm run lint
- name: Test Node
run: npm run test-node
- name: Test browsers
run: |
sudo npx playwright install-deps
npm run test-browser

0 comments on commit 40cc7f4

Please sign in to comment.