-
Notifications
You must be signed in to change notification settings - Fork 0
/
tox.ini
37 lines (32 loc) · 1.04 KB
/
tox.ini
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
[tox]
env_list =
py3.{9,10,12}-test
[testenv]
deps =
-r requirements-dev.txt
[testenv:py3.{9,10,12}-test]
description = run the tests with pytest
commands =
pytest tests/antares {posargs}
[testenv:coverage]
description = Run tests with coverage (with Python 3.11 inside the CI)
commands =
pytest --cov src --cov-report xml tests/antares
[testenv:lint]
description = linting with ruff
skip_install = True
commands =
python scripts/license_checker_and_adder.py --path=src --action=fix
python scripts/license_checker_and_adder.py --path=tests --action=fix
ruff check --fix src/ tests/ {posargs}
ruff format src/ tests/ {posargs}
mypy {posargs}
[testenv:lint-ci]
description = Linting and formatting with ruff, typing with mypy
skip_install = True
commands =
python scripts/license_checker_and_adder.py --path=src --action=check-strict
python scripts/license_checker_and_adder.py --path=tests --action=check-strict
ruff check src/ tests/ {posargs}
ruff format --check src/ tests/ {posargs}
mypy {posargs}