mirror of
https://github.com/fastapi-users/fastapi-users.git
synced 2025-11-02 21:24:34 +08:00
Add typecheck to build steps
This commit is contained in:
9
.github/workflows/build.yml
vendored
9
.github/workflows/build.yml
vendored
@ -21,9 +21,12 @@ jobs:
|
||||
python -m pip install --upgrade pip
|
||||
pip install -r requirements.dev.txt
|
||||
- name: Check codestyle
|
||||
run: make format-check
|
||||
- name: Lint
|
||||
run: make lint
|
||||
run: |
|
||||
make format-check
|
||||
make lint
|
||||
- name: Typecheck
|
||||
run: |
|
||||
make typecheck
|
||||
- name: Test with pytest
|
||||
env:
|
||||
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
|
||||
|
||||
3
Makefile
3
Makefile
@ -25,6 +25,9 @@ format-check: isort-src-check isort-docs-check isort-examples-check
|
||||
lint:
|
||||
flake8 ./fastapi_users ./tests
|
||||
|
||||
typecheck:
|
||||
mypy fastapi_users/
|
||||
|
||||
test:
|
||||
pytest --cov=fastapi_users/ --cov-report=term-missing --cov-fail-under=100
|
||||
|
||||
|
||||
@ -9,6 +9,22 @@ ignore_missing_imports = true
|
||||
module = "passlib.*"
|
||||
ignore_missing_imports = true
|
||||
|
||||
[[tool.mypy.overrides]]
|
||||
module = "fastapi_users_db_mongodb.*"
|
||||
ignore_missing_imports = true
|
||||
|
||||
[[tool.mypy.overrides]]
|
||||
module = "fastapi_users_db_sqlalchemy.*"
|
||||
ignore_missing_imports = true
|
||||
|
||||
[[tool.mypy.overrides]]
|
||||
module = "fastapi_users_db_tortoise.*"
|
||||
ignore_missing_imports = true
|
||||
|
||||
[[tool.mypy.overrides]]
|
||||
module = "fastapi_users_db_ormar.*"
|
||||
ignore_missing_imports = true
|
||||
|
||||
[tool.pytest.ini_options]
|
||||
asyncio_mode = "auto"
|
||||
addopts = "--ignore=test_build.py"
|
||||
|
||||
Reference in New Issue
Block a user