Skip to content

Commit

Permalink
Start using github actions matrix to run tests instead of tox and add…
Browse files Browse the repository at this point in the history
… running mypy
  • Loading branch information
jmichalicek committed Aug 28, 2024
1 parent 7d58e87 commit 01e44e5
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 6 deletions.
17 changes: 12 additions & 5 deletions .github/workflows/run-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,12 @@ jobs:
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13.0-rc.1"]
django-version: ["django==4.2.*", "django==5.0.*", "django==5.1.*", "django==5.2.*"]
exclude:
- python-version: "3.12"
django-version: "django<4.2.8"
- python-version: "3.13.0-rc.1"
django-version: "django<5.2"
django-version: ["django==5.1.*", "django==5.0.*", "django==4.2.*"]
- python-version: "3.8"
django-version: ["django==5.0.*", "django==5.1.*", "django==5.2.*"]
- python-version: "3.9"
django-version: ["django==5.0.*", "django==5.1.*", "django==5.2.*"]
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
Expand All @@ -30,9 +32,14 @@ jobs:
run: |
python -m pip install --upgrade pip
pip install -r requirements_test.txt
pip install -c requirements_test.txt ${{ matrix.django-version }}
- name: Lint with ruff
run: |
# stop the build if there are Python syntax errors or undefined names
make ruff-check
- name: Run Tox
run: tox
- name: MyPy
run: cd django_mail_viewer && mypy .
- name: Run Tests
run: |
coverage run --source django_mail_viewer runtests.py
coverage report
2 changes: 1 addition & 1 deletion tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ python =
3.9: py39
3.10: py310
3.11: py311
3.11: py312
3.12: py312

[testenv]
setenv =
Expand Down

0 comments on commit 01e44e5

Please sign in to comment.