-
Notifications
You must be signed in to change notification settings - Fork 0
105 lines (84 loc) · 2.85 KB
/
Copy pathci.yml
File metadata and controls
105 lines (84 loc) · 2.85 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
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
name: ci
on:
pull_request:
branches: [main]
push:
branches: [main]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
node:
name: node (${{ matrix.os }}, node ${{ matrix.node }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest]
node: ["20.17.0"]
steps:
- name: Checkout
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- name: Setup Node
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4.0.3
with:
node-version-file: .nvmrc
cache: npm
- name: Install
run: npm ci
- name: Typecheck
run: npm run typecheck
- name: Validate questionnaire
run: npm run validate:questionnaire
- name: Validate profiles
run: npm run validate:profiles
- name: Validate generator (smoke — 3 canonical profiles)
run: npm run validate:generator
- name: Render generator (dry-run — 3 canonical profiles)
run: npm run render:generator
- name: Test (with coverage)
run: npm run test:coverage
python:
name: python (${{ matrix.os }}, py ${{ matrix.python }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest]
python: ["3.10", "3.11"]
steps:
- name: Checkout
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- name: Setup Python
uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0
with:
python-version: ${{ matrix.python }}
cache: pip
cache-dependency-path: requirements-dev.txt
- name: Install dev deps
run: python -m pip install --upgrade pip && pip install -r requirements-dev.txt
- name: Pytest hooks (with coverage)
run: pytest hooks/tests -q --cov=hooks --cov-report=term-missing
selftest:
name: selftest (ubuntu, py 3.11)
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- name: Setup Node
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4.0.3
with:
node-version-file: .nvmrc
cache: npm
- name: Install Node deps
run: npm ci
- name: Setup Python
uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0
with:
python-version: "3.11"
cache: pip
cache-dependency-path: requirements-dev.txt
- name: Install dev deps
run: python -m pip install --upgrade pip && pip install -r requirements-dev.txt
- name: Pytest selftest (smoke + scenarios)
run: pytest bin/tests -q