-
Notifications
You must be signed in to change notification settings - Fork 2
70 lines (52 loc) · 1.55 KB
/
ci.yml
File metadata and controls
70 lines (52 loc) · 1.55 KB
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
65
66
67
68
69
70
name: CI
on:
pull_request:
branches: [main]
jobs:
ci:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
cache: npm
- run: npm ci
- name: Format check
run: npm run format:check
- name: Lint
run: npm run lint
- name: Spell check
uses: streetsidesoftware/cspell-action@v6
with:
files: "src/**/*.ts"
- name: Build
run: npm run compile
- name: Unit tests
run: npm run test:unit
- name: E2E tests with coverage
run: xvfb-run -a npx vscode-test --coverage --coverage-reporter json-summary --coverage-reporter text --coverage-reporter html --coverage-reporter lcov --grep @exclude-ci --invert
- name: Debug coverage output
if: always()
run: ls -la coverage/ || echo "No coverage directory"
- name: Coverage threshold (90%)
run: npm run coverage:check
website:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
- name: Install dependencies
run: npm ci
working-directory: website
- name: Build site
run: npx @11ty/eleventy
working-directory: website
- name: Install Playwright
run: npx playwright install --with-deps chromium
working-directory: website
- name: Run website tests
run: npx playwright test
working-directory: website