Skip to content

Commit 01018df

Browse files
committed
correct tests
1 parent aa3a85f commit 01018df

1 file changed

Lines changed: 15 additions & 15 deletions

File tree

.github/workflows/test-python-setup-uv.yml

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -42,9 +42,9 @@ jobs:
4242
uv --version
4343
uv pip list
4444
# Verify core dependency is installed
45-
python -c "import requests; print('[OK] Core dependency installed')"
45+
uv run python -c "import requests; print('[OK] Core dependency installed')"
4646
# Verify dev group is NOT installed (default is now empty)
47-
if python -c "import pytest" 2>/dev/null; then
47+
if uv run python -c "import pytest" 2>/dev/null; then
4848
echo "[ERROR] pytest should not be installed"
4949
exit 1
5050
else
@@ -86,10 +86,10 @@ jobs:
8686
run: |
8787
uv pip list
8888
# Verify test and docs groups are installed
89-
python -c "import pytest_cov; import pytest_mock; print('[OK] Test dependencies installed')"
90-
python -c "import mkdocs; print('[OK] Docs dependencies installed')"
89+
uv run python -c "import pytest_cov; import pytest_mock; print('[OK] Test dependencies installed')"
90+
uv run python -c "import mkdocs; print('[OK] Docs dependencies installed')"
9191
# Verify dev group is NOT installed
92-
if python -c "import black" 2>/dev/null; then
92+
if uv run python -c "import black" 2>/dev/null; then
9393
echo "[ERROR] black should not be installed"
9494
exit 1
9595
else
@@ -129,9 +129,9 @@ jobs:
129129
run: |
130130
uv pip list
131131
# Verify core dependency is installed
132-
python -c "import requests; print('[OK] Core dependency installed')"
132+
uv run python -c "import requests; print('[OK] Core dependency installed')"
133133
# Verify dev group is NOT installed
134-
if python -c "import pytest" 2>/dev/null; then
134+
if uv run python -c "import pytest" 2>/dev/null; then
135135
echo "[ERROR] pytest should not be installed"
136136
exit 1
137137
else
@@ -201,7 +201,7 @@ jobs:
201201
shell: bash
202202
run: |
203203
uv pip list
204-
python -c "import requests; print('[OK] Dependencies installed without lock verification')"
204+
uv run python -c "import requests; print('[OK] Dependencies installed without lock verification')"
205205
206206
test-uv-lock-verification-fail:
207207
name: Test uv action - Lock verification failure
@@ -291,13 +291,13 @@ jobs:
291291
shell: bash
292292
run: |
293293
python --version
294-
python -c "import sys; assert sys.version_info[:2] == tuple(map(int, '${{ matrix.python-version }}'.split('.')[:2]))"
294+
uv run python -c "import sys; assert sys.version_info[:2] == tuple(map(int, '${{ matrix.python-version }}'.split('.')[:2]))"
295295
uv pip list
296296
297297
- name: Test uv functionality
298298
shell: bash
299299
run: |
300-
python -c "import requests; import pytest; print(f'[OK] Python ${{ matrix.python-version }} working on ${{ matrix.os }}')"
300+
uv run python -c "import requests; import pytest; print(f'[OK] Python ${{ matrix.python-version }} working on ${{ matrix.os }}')"
301301
302302
test-uv-cache:
303303
name: Test uv action - Cache functionality
@@ -364,7 +364,7 @@ jobs:
364364
- name: Verify all groups installed
365365
shell: bash
366366
run: |
367-
python -c "import pytest; import pytest_cov; import mkdocs; print('[OK] All comma-separated groups installed')"
367+
uv run python -c "import pytest; import pytest_cov; import mkdocs; print('[OK] All comma-separated groups installed')"
368368
369369
test-uv-mixed-separators:
370370
name: Test uv action - Mixed separators (space and comma)
@@ -399,7 +399,7 @@ jobs:
399399
- name: Verify all groups installed
400400
shell: bash
401401
run: |
402-
python -c "import pytest; import pytest_cov; import mkdocs; print('[OK] All mixed-separator groups installed')"
402+
uv run python -c "import pytest; import pytest_cov; import mkdocs; print('[OK] All mixed-separator groups installed')"
403403
404404
test-uv-space-separated-groups:
405405
name: Test uv action - Space-separated groups
@@ -434,7 +434,7 @@ jobs:
434434
- name: Verify all groups installed
435435
shell: bash
436436
run: |
437-
python -c "import pytest; import pytest_cov; import mkdocs; print('[OK] All space-separated groups installed')"
437+
uv run python -c "import pytest; import pytest_cov; import mkdocs; print('[OK] All space-separated groups installed')"
438438
439439
test-uv-no-dependency-groups-section:
440440
name: Test uv action - No dependency-groups section
@@ -462,7 +462,7 @@ jobs:
462462
- name: Verify action succeeded with core dependencies only
463463
shell: bash
464464
run: |
465-
python -c "import requests; print('[OK] Core dependencies installed without dependency-groups section')"
465+
uv run python -c "import requests; print('[OK] Core dependencies installed without dependency-groups section')"
466466
uv pip list
467467
echo "[OK] Action succeeded without dependency-groups section"
468468
@@ -497,4 +497,4 @@ jobs:
497497
- name: Verify dev group installed
498498
shell: bash
499499
run: |
500-
python -c "import pytest; import black; print('[OK] Dev group explicitly installed')"
500+
uv run python -c "import pytest; import black; print('[OK] Dev group explicitly installed')"

0 commit comments

Comments
 (0)