Add two async tests examples #10
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Run Tests | |
on: | |
push: | |
branches: | |
- '*' | |
pull_request: | |
branches: | |
- master | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Cache npm deps | |
uses: actions/cache@v2 | |
with: | |
path: | | |
node_modules | |
~/.npm | |
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }} | |
restore-keys: ${{ runner.os }}-node | |
- name: Install dependencies | |
run: npm i | |
- name: Run tests | |
uses: coactions/setup-xvfb@v1 | |
with: | |
run: npm test |