-
Notifications
You must be signed in to change notification settings - Fork 126
26 lines (26 loc) · 1.32 KB
/
test_lint_python.yml
File metadata and controls
26 lines (26 loc) · 1.32 KB
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
name: test_and_lint
on: [pull_request, push]
jobs:
test_and_lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.9'
- uses: abatilo/actions-poetry@v3
- run: poetry config virtualenvs.create true --local
- run: poetry config virtualenvs.in-project true --local
- run: poetry install
- run: poetry run bandit --recursive --skip B101 delorean || true # B101 is assert statements
- run: poetry run black --check delorean || true
- run: poetry run codespell delorean || true # --ignore-words-list="" --skip="*.css,*.js,*.lock"
- run: poetry run flake8 delorean --count --select=E9,F63,F7,F82 --show-source --statistics
- run: poetry run flake8 delorean --count --exit-zero --max-complexity=10 --max-line-length=88
--show-source --statistics || true
- run: poetry run isort --check-only --profile black delorean || true
- run: mkdir --parents --verbose .mypy_cache
- run: poetry run mypy --ignore-missing-imports --install-types --non-interactive --exclude ./docs/ delorean
- run: poetry run pytest tests/delorean_tests.py
- run: poetry run pytest --doctest-modules
- run: poetry run nosetests --with-coverage --cover-package=delorean