|
9 | 9 |
|
10 | 10 | strategy:
|
11 | 11 | matrix:
|
12 |
| - python-version: ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"] |
| 12 | + python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"] |
13 | 13 |
|
14 | 14 | steps:
|
15 | 15 | #----------------------------------------------
|
16 |
| - #---- Checkout and install poetry and python |
| 16 | + #---- Checkout and install uv and python |
17 | 17 | #----------------------------------------------
|
18 | 18 |
|
19 | 19 | - uses: actions/checkout@v4
|
20 |
| - - name: Install poetry |
21 |
| - run: pipx install poetry |
22 |
| - - uses: actions/setup-python@v5 |
| 20 | + - name: Install uv |
| 21 | + uses: astral-sh/setup-uv@v4 |
23 | 22 | with:
|
24 |
| - python-version: ${{ matrix.python-version }} |
25 |
| - cache: 'poetry' |
| 23 | + enable-cache: true |
| 24 | + - name: Set up Python ${{ matrix.python-version }} |
| 25 | + run: uv python install ${{ matrix.python-version }} |
26 | 26 |
|
27 | 27 | #----------------------------------------------
|
28 | 28 | #---- Install dependencies
|
29 | 29 | #----------------------------------------------
|
30 | 30 |
|
31 |
| - - name: Poetry install |
32 |
| - run: poetry install |
| 31 | + - name: uv install |
| 32 | + run: uv sync --all-extras --dev |
33 | 33 |
|
34 | 34 | #----------------------------------------------
|
35 | 35 | #---- Show installation details
|
36 | 36 | #----------------------------------------------
|
37 | 37 |
|
38 |
| - - name: poetry --version |
39 |
| - run: poetry --version |
40 |
| - - name: poetry run python --version |
41 |
| - run: poetry run python --version |
| 38 | + - name: uv --version |
| 39 | + run: uv --version |
| 40 | + - name: uv run python --version |
| 41 | + run: uv run python --version |
42 | 42 | - name: ls -lah
|
43 | 43 | run: ls -lah
|
44 |
| - - name: poetry show |
45 |
| - run: poetry show |
46 |
| - - name: poetry show --tree |
47 |
| - run: poetry show --tree |
| 44 | + - name: uv tree |
| 45 | + run: uv tree |
48 | 46 |
|
49 | 47 | #----------------------------------------------
|
50 | 48 | #---- Pre-Checks
|
51 | 49 | #----------------------------------------------
|
52 | 50 |
|
53 | 51 | - name: Show clock resolution
|
54 |
| - run: poetry run python tests/system_checks/test_tick_rate.py |
| 52 | + run: uv run python tests/system_checks/test_tick_rate.py |
55 | 53 | - name: Test clocks
|
56 |
| - run: poetry run python tests/system_checks/test_clocks.py |
| 54 | + run: uv run python tests/system_checks/test_clocks.py |
57 | 55 | - name: Test monotonicity
|
58 |
| - run: poetry run python tests/system_checks/test_monotonic_over_threads.py |
| 56 | + run: uv run python tests/system_checks/test_monotonic_over_threads.py |
59 | 57 |
|
60 | 58 | #----------------------------------------------
|
61 | 59 | #---- Run tests with coverage report
|
62 | 60 | #----------------------------------------------
|
63 | 61 |
|
64 | 62 | - name: 🚀 Run tests with code coverage report
|
65 |
| - run: poetry run pytest --cov=dictdatabase --cov-report term-missing |
| 63 | + run: uv run pytest --cov=dictdatabase --cov-report term-missing |
66 | 64 |
|
67 | 65 | #----------------------------------------------
|
68 | 66 | #---- Save coverage artifact
|
|
79 | 77 |
|
80 | 78 | # JOB: Coverage Badge
|
81 | 79 | cov-badge-job:
|
| 80 | + # Only run this job on push events to the main branch, after tests succeed |
| 81 | + if: github.event_name == 'push' && github.ref == 'refs/heads/main' && needs.tests-job.result == 'success' |
82 | 82 | needs: tests-job
|
83 | 83 | runs-on: ubuntu-latest
|
84 | 84 | steps:
|
@@ -113,7 +113,7 @@ jobs:
|
113 | 113 | #----------------------------------------------
|
114 | 114 |
|
115 | 115 | - name: Verify Changed Files
|
116 |
| - uses: tj-actions/verify-changed-files@v16 |
| 116 | + uses: tj-actions/verify-changed-files@v17 |
117 | 117 | id: changed_files
|
118 | 118 | with:
|
119 | 119 | files: assets/coverage.svg
|
|
0 commit comments