Skip to content

Commit 24bf895

Browse files
committed
Add mypy to test action
1 parent 371a75c commit 24bf895

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

.github/workflows/test.yml

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,19 +18,22 @@ jobs:
1818
with:
1919
python-version: "3.10"
2020

21-
- name: Check formatting with Ruff
21+
- name: Lint with Ruff
2222
uses: astral-sh/ruff-action@v3
2323
with:
24-
args: format --check --diff --exclude docs,tests
24+
args: check --exclude docs,tests
2525

26-
- name: Lint with Ruff
26+
- name: Check formatting with Ruff
2727
uses: astral-sh/ruff-action@v3
2828
with:
29-
args: check --exclude docs,tests
29+
args: format --check --diff --exclude docs,tests
3030

3131
- name: Install package and its dependencies
3232
run: pip install --editable .[dev,idxml]
3333

34+
- name: Static type checking with mypy
35+
run: mypy
36+
3437
- name: Test with pytest and codecov
3538
run: |
3639
pytest --cov=psm_utils --cov-report=xml tests/

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ dependencies = [
3333
]
3434

3535
[project.optional-dependencies]
36-
dev = ["ruff", "isort>5", "pytest", "pytest-cov"]
36+
dev = ["ruff", "isort>5", "pytest", "pytest-cov", "mypy"]
3737
docs = [
3838
"numpydoc>=1,<2",
3939
"recommonmark",

0 commit comments

Comments
 (0)