-
-
Notifications
You must be signed in to change notification settings - Fork 17
64 lines (51 loc) · 1.61 KB
/
ci.yml
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
name: CI
on:
push:
branches: [main]
pull_request:
types:
- opened
- synchronize
workflow_dispatch:
jobs:
build:
name: Build, lint and test
runs-on: ubuntu-latest
steps:
- name: 🛒 Checkout repo
uses: actions/checkout@v3
- uses: pnpm/action-setup@v2
- name: ⚒️ Use Node.js
uses: actions/setup-node@v3
with:
node-version-file: '.nvmrc'
cache: 'pnpm'
- name: 📦 Install Dependencies
run: npm run bootstrap
- name: 🚦 Lint
run: pnpm run lint
- name: 🔨 Build
run: pnpm run --filter react-compare-slider build
- name: 🧑🏫 Build Example Project
run: pnpm run --filter @this/example build
- name: 🕵️ Check Package Configuration
run: pnpm run --filter react-compare-slider check:package
- name: 🧪 Test
run: |
pnpm dlx [email protected] install --with-deps chromium
pnpm run test:ci
- name: Upload Code Climate Test Coverage
uses: paambaati/[email protected]
env:
CC_TEST_REPORTER_ID: '${{ secrets.CC_TEST_REPORTER_ID }}'
with:
debug: true
coverageLocations: |
${{github.workspace}}/coverage/ssr-tests/*.info:lcov
${{github.workspace}}/coverage/storybook/*.info:lcov
- uses: preactjs/compressed-size-action@v2
with:
repo-token: '${{ secrets.GITHUB_TOKEN }}'
install-script: 'pnpm install --frozen-lockfile --filter react-compare-slider'
build-script: 'build'
cwd: lib