Repository navigation
63 lines (53 loc) · 1.85 KB
/
Copy pathtests.yml
File metadata and controls
63 lines (53 loc) · 1.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
name: Tests
on:
push:
branches: [main, master]
pull_request:
branches: [main, master]
workflow_dispatch:
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10", "3.11"]
steps:
- uses: actions/checkout@v7
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v7
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
pip install torch==2.1.0 --index-url https://download.pytorch.org/whl/cpu
pip install -e ".[dev]"
- name: Run paste losslessness test
run: pytest tests/test_paste_lossless.py -v
- name: Check public documentation and CLI discovery
run: |
python scripts/check_docs.py
python -m layercake --help
- name: Run rolling-training smoke tests
run: |
python -m layercake.rolling.cli --help
python scripts/demo_rolling_training.py --smoke
python scripts/demo_preview_guided_layercake_training.py --smoke
# The Tier 1 timing benchmark is intentionally not a CI pass/fail gate.
# Shared-runner timing is noisy, while the benchmark itself correctly
# exits nonzero when a scientific dominance gate is missed. Its portable
# schema and fail-closed gates are exercised by the pytest suite below.
- name: Run portable test suite
run: |
pytest -q
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: actions/setup-python@v7
with:
python-version: "3.11"
- name: Lint with ruff
run: |
pip install ruff
ruff check layercake/__init__.py layercake/__main__.py layercake/cake \
layercake/routing/orchestrator.py tests/test_main_cli.py scripts/check_docs.py