Repository navigation
101 lines (94 loc) · 2.87 KB
/
Copy pathci.yml
File metadata and controls
101 lines (94 loc) · 2.87 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
name: CI
on:
push:
branches: [main]
pull_request:
# the Deck model workflow dispatches CI on the pull request it opens
workflow_dispatch:
workflow_call:
permissions:
contents: read
concurrency:
group: ci-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
test:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.11", "3.12", "3.13", "3.14"]
steps:
- uses: actions/checkout@v7
- uses: actions/setup-python@v7
with:
python-version: ${{ matrix.python-version }}
cache: pip
cache-dependency-path: pyproject.toml
- name: Install (with the deck model and the fonts extra)
run: |
python -m pip install --upgrade pip
python -m pip install -e ".[test,deck,fonts,remote]"
- name: Lint
run: |
python -m ruff check .
python -m ruff format --check .
lint-imports
- name: Command line
run: python -m nnnotes --help
- name: Test
run: python -m pytest
types:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: actions/setup-python@v7
with:
python-version: "3.13"
cache: pip
cache-dependency-path: pyproject.toml
- name: Install
run: |
python -m pip install --upgrade pip
python -m pip install -e ".[test,deck,fonts,remote]"
- name: Type check
run: python -m pyright
goldens:
# The golden records of the stages (tests/golden/*.json) were made with these library versions; with the same
# versions installed an output change without a stage or converter version bump fails instead of being skipped.
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: actions/setup-node@v7
with:
node-version: "24"
- uses: actions/setup-python@v7
with:
python-version: "3.13"
cache: pip
cache-dependency-path: |
pyproject.toml
.github/goldens-constraints.txt
- name: Install (pinned)
run: |
python -m pip install --upgrade pip
python -m pip install -c .github/goldens-constraints.txt -e ".[test,fonts]"
- name: Golden records
env:
GOLDENS_STRICT: "1"
run: python -m pytest tests/pipeline/test_goldens.py tests/pipeline/test_objexport.py
docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: actions/setup-python@v7
with:
python-version: "3.13"
cache: pip
cache-dependency-path: pyproject.toml
- name: Install
run: |
python -m pip install --upgrade pip
python -m pip install -e ".[docs]"
- name: Build the documentation site
run: python -m mkdocs build --strict