Skip to content

Commit

Permalink
Check
Browse files Browse the repository at this point in the history
Signed-off-by: Nicola Sella <[email protected]>
  • Loading branch information
inknos committed Nov 29, 2024
1 parent 06768b0 commit 2d7edd9
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 12 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ podman:

.PHONY: lint
lint: tox
$(PYTHON) -m tox -e black,pylint
$(PYTHON) -m tox -e format,lint

.PHONY: tests
tests: tox
Expand Down
3 changes: 1 addition & 2 deletions test-requirements.txt
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
# Any changes should be copied into pyproject.toml
-r requirements.txt
black
ruff
coverage
fixtures
pylint
pytest
requests-mock >= 1.11.0
tox
22 changes: 13 additions & 9 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tox]
minversion = 3.2.0
envlist = pylint,coverage,py39,py310,py311,py312,py313
envlist = coverage,py39,py310,py311,py312,py313
ignore_basepython_conflict = true

[testenv]
Expand All @@ -17,21 +17,25 @@ setenv =
[testenv:venv]
commands = {posargs}

[testenv:pylint]
depends = py310
basepython = python3.10
allowlist_externals = pylint
commands = pylint podman
[testenv:lint]
depends = ruff
allowlist_externals = ruff
commands = ruff check --diff

# TODO: add pylint as alias of lint for compatibility

[testenv:coverage]
commands =
coverage run -m pytest
coverage report -m --skip-covered --fail-under=80 --omit=podman/tests/* --omit=.tox/*

[testenv:black]
deps = black
[testenv:format]
deps = ruff
allowlist_externals = ruff
commands =
black --diff --check .
ruff format --diff

# TODO: add black as alias of format for compatibility

[testenv:black-format]
deps = black
Expand Down

0 comments on commit 2d7edd9

Please sign in to comment.