-
Notifications
You must be signed in to change notification settings - Fork 67
42 lines (31 loc) · 1.11 KB
/
continuous-integration.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
name: CI
on: [push, pull_request]
jobs:
test:
runs-on: ubuntu-latest
env:
BROWSERSTACK_ACCESS_KEY: ${{ secrets.BROWSERSTACK_ACCESS_KEY }}
BROWSERSTACK_USERNAME: ${{ secrets.BROWSERSTACK_USERNAME }}
CODACY_PROJECT_TOKEN: ${{ secrets.CODACY_PROJECT_TOKEN }}
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Install NodeJS
uses: actions/setup-node@v2
with:
node-version: '14'
- name: Update npm
run: npm install -g [email protected]
- name: Install npm packages for PDF-viewer-reactjs Package
run: npm install
- name: Build PDF-viewer-reactjs Package
run: npm run build
- name: Upload coverage to Codacy
run: bash <(curl -Ls https://coverage.codacy.com/get.sh) report
- name: Upload coverage to Codecov
run: bash <(curl -s https://codecov.io/bash)
- name: Install npm packages for Example App
run: npm install --prefix example/
- name: Run tests for Example App
run: npm test --prefix example/