File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2626 run : pip install -e .[test]
2727
2828 - name : Tests
29- run : scripts/test.sh
29+ run : scripts/test
3030
3131 - name : Upload coverage
3232 uses : codecov/codecov-action@v3
Original file line number Diff line number Diff line change @@ -60,20 +60,17 @@ changelog = "https://fastapi-debug-toolbar.domake.io/changelog/"
6060
6161[project .optional-dependencies ]
6262test = [
63- " black" ,
64- " codecov" ,
65- " flake8" ,
63+ " bandit" ,
64+ " coverage" ,
6665 " httpx" ,
67- " isort" ,
6866 " itsdangerous" ,
6967 " mypy" ,
7068 " pytest" ,
7169 " pytest-asyncio" ,
72- " pytest-cov" ,
7370 " python-multipart" ,
71+ " ruff" ,
7472 " SQLAlchemy" ,
75- " tortoise-orm >=0.19.0" ,
76- " types-setuptools" ,
73+ " tortoise-orm" ,
7774]
7875
7976doc = [
@@ -92,11 +89,28 @@ packages = ["debug_toolbar"]
9289[tool .hatch .version ]
9390path = " debug_toolbar/__init__.py"
9491
95- [tool .isort ]
96- profile = " black"
97-
9892[tool .mypy ]
9993ignore_missing_imports = true
10094
95+ [tool .ruff .lint ]
96+ select = [
97+ " E" , # pycodestyle errors
98+ " W" , # pycodestyle warnings
99+ " F" , # pyflakes
100+ " I" , # isort
101+ " C" , # flake8-comprehensions
102+ " B" , # flake8-bugbear
103+ ]
104+
105+ [tool .ruff .lint .flake8-bugbear ]
106+ extend-immutable-calls = [" fastapi.Depends" ]
107+
108+ [tool .bandit ]
109+ skips = [" B101" ]
110+
101111[tool .pytest .ini_options ]
112+ addopts = [" --strict-config" , " --strict-markers" ]
102113asyncio_mode = " auto"
114+
115+ [tool .coverage .run ]
116+ source_pkgs = [" app" , " tests" ]
Original file line number Diff line number Diff line change 1+ #! /bin/sh
2+
3+ set -e
4+ set -x
5+
6+ ruff debug_toolbar tests scripts
7+ ruff format debug_toolbar tests --check
8+ bandit --configfile pyproject.toml --recursive debug_toolbar
9+ mypy --install-types --non-interactive debug_toolbar tests
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1+ #! /bin/sh
2+
3+ set -e
4+ set -x
5+
6+ scripts/lint
7+ coverage run -m pytest $@
8+ coverage report --show-missing
9+ coverage xml
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments