1919 - cron : " 0 0 * * 1"
2020
2121env :
22- UV_SYSTEM_PYTHON : 1
22+ UV_NO_SYNC : true
2323
2424jobs :
2525 test :
4444 python-version : " 3.13"
4545 fail-fast : false
4646 runs-on : ${{ matrix.os }}
47+ env :
48+ UV_PYTHON : ${{ matrix.python-version }}
4749 steps :
4850 - uses : actions/checkout@v6
4951 - name : Set up Python
@@ -53,25 +55,25 @@ jobs:
5355 - name : Setup uv
5456 uses : astral-sh/setup-uv@v7
5557 with :
56- version : " 0.9.6"
5758 enable-cache : true
5859 cache-dependency-glob : |
59- requirements**.txt
6060 pyproject.toml
61+ uv.lock
6162 # Allow debugging with tmate
6263 - name : Setup tmate session
6364 uses : mxschmitt/action-tmate@v3
6465 if : ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.debug_enabled == 'true' }}
6566 with :
6667 limit-access-to-actor : true
6768 - name : Install Dependencies
68- run : uv pip install -r requirements- tests.txt
69+ run : uv sync --locked --no-dev --group tests
6970 - run : mkdir coverage
7071 - name : Test
71- run : bash scripts/test.sh
72+ run : uv run bash scripts/test.sh
7273 env :
7374 COVERAGE_FILE : coverage/.coverage.${{ runner.os }}-py${{ matrix.python-version }}
7475 CONTEXT : ${{ runner.os }}-py${{ matrix.python-version }}
76+ UV_PYTHON : " " # Would affect uv subprocesses spawened by fastapi-new
7577 - name : Store coverage files
7678 uses : actions/upload-artifact@v6
7779 with :
@@ -87,15 +89,14 @@ jobs:
8789 - uses : actions/checkout@v6
8890 - uses : actions/setup-python@v6
8991 with :
90- python-version : ' 3.13 '
92+ python-version-file : " .python-version "
9193 - name : Setup uv
9294 uses : astral-sh/setup-uv@v7
9395 with :
94- version : " 0.9.6"
9596 enable-cache : true
9697 cache-dependency-glob : |
97- requirements**.txt
9898 pyproject.toml
99+ uv.lock
99100 - name : Get coverage files
100101 uses : actions/download-artifact@v7
101102 with :
@@ -109,17 +110,17 @@ jobs:
109110 with :
110111 limit-access-to-actor : true
111112 - name : Install Dependencies
112- run : uv pip install -r requirements- tests.txt
113+ run : uv sync --locked --no-dev --group tests
113114 - run : ls -la coverage
114- - run : coverage combine coverage
115- - run : coverage html --title "Coverage for ${{ github.sha }}"
115+ - run : uv run coverage combine coverage
116+ - run : uv run coverage html --title "Coverage for ${{ github.sha }}"
116117 - name : Store coverage HTML
117118 uses : actions/upload-artifact@v6
118119 with :
119120 name : coverage-html
120121 path : htmlcov
121122 include-hidden-files : true
122- - run : coverage report --fail-under=100
123+ - run : uv run coverage report --fail-under=100
123124
124125 # https://github.com/marketplace/actions/alls-green#why
125126 alls-green : # This job does nothing and is only used for the branch protection
0 commit comments