-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Triggers the workflow on push or pull-request events. Do not use pip caching since it looks for a requirement.txt file that does not exist.
- Loading branch information
Showing
1 changed file
with
32 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
# GitHub actions workflow for testing pylint-silent. | ||
|
||
name: run tests | ||
|
||
# Triggers the workflow on push or pull-request events. | ||
on: [push, pull_request] | ||
|
||
jobs: | ||
tests: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
# Run on earliest and latest supported python versions. | ||
python-version: ["3.7", "3.11"] | ||
# Run linters and pytests. | ||
testsuite: ["linters", "pytest"] | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-python@v5 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: install pip and tox | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install tox | ||
- name: run linters | ||
# Linters are only run on the earliest supported python version. | ||
if: ${{ matrix.python-version == '3.7' && matrix.testsuite == 'linters' }} | ||
run: tox -e py3-pytest | ||
- name: run pytest | ||
if: ${{ matrix.testsuite == 'pytest' }} | ||
run: tox -e mypy,pep8,pylint |