Skip to content

Commit

Permalink
Test with tox-uv (#226)
Browse files Browse the repository at this point in the history
  • Loading branch information
hugovk authored Oct 17, 2024
2 parents 5a0c9b4 + 2e074e4 commit 042a3ab
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 15 deletions.
14 changes: 5 additions & 9 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ permissions:

env:
FORCE_COLOR: 1
PIP_DISABLE_PIP_VERSION_CHECK: 1

jobs:
test:
Expand All @@ -26,25 +25,22 @@ jobs:
with:
python-version: ${{ matrix.python-version }}
allow-prereleases: true
cache: pip

- name: Install dependencies
run: |
python -m pip install -U pip
python -m pip install -U tox
- name: Install uv
uses: hynek/setup-cached-uv@v2

- name: Tox tests
run: |
tox -e py
uvx --with tox-uv tox -e py
- name: Test CLI
run: |
tox -e cli
uvx --with tox-uv tox -e cli
- name: Tox tests (pins)
if: matrix.python-version == '3.12' && matrix.os == 'ubuntu-latest'
run: |
tox -e pins
uvx --with tox-uv tox -e pins
- name: Upload coverage
uses: codecov/[email protected]
Expand Down
9 changes: 5 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -85,10 +85,11 @@ lint.select = [
"YTT", # flake8-2020
]
lint.ignore = [
"E203", # Whitespace before ':'
"E221", # Multiple spaces before operator
"E226", # Missing whitespace around arithmetic operator
"E241", # Multiple spaces after ','
"E203", # Whitespace before ':'
"E221", # Multiple spaces before operator
"E226", # Missing whitespace around arithmetic operator
"E241", # Multiple spaces after ','
"UP038", # Makes code slower and more verbose
]
lint.flake8-import-conventions.aliases.datetime = "dt"
lint.flake8-import-conventions.banned-from = [ "datetime" ]
Expand Down
4 changes: 2 additions & 2 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ commands =
pre-commit run --all-files --show-diff-on-failure

[testenv:pins]
deps =
-r requirements.txt
extras =
None
commands_pre =
{envpython} -m pip install -r requirements.txt

0 comments on commit 042a3ab

Please sign in to comment.