Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
00a0975
commit d261f3c
Showing
1 changed file
with
44 additions
and
15 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 |
---|---|---|
@@ -1,22 +1,51 @@ | ||
name: Run tests | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
paths: | ||
- '.github/workflows/test.yml' | ||
- '**.py' | ||
push: | ||
paths: | ||
- '.github/workflows/test.yml' | ||
- '**.py' | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
test: | ||
runs-on: ${{ matrix.os }}-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [ubuntu] | ||
python_version: ['3.6', '3.7', '3.8'] | ||
|
||
steps: | ||
- uses: actions/checkout@1.0.0 | ||
- uses: excitedleigh/setup-nox@0.1.0 | ||
- name: Run tests | ||
run: nox | ||
- name: Submit coverage results | ||
env: | ||
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }} | ||
run: | | ||
pip install coveralls | ||
coveralls | ||
- uses: actions/checkout@v1 | ||
|
||
- uses: actions/setup-python@v1 | ||
name: Install Python ${{ matrix.python_version }} | ||
with: | ||
python-version: ${{ matrix.python_version }} | ||
|
||
- uses: actions/setup-python@v1 | ||
name: Install Python 3.x | ||
with: | ||
python-version: 3.x | ||
|
||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
python -m pip install nox | ||
shell: bash | ||
|
||
- name: Run tests | ||
run: | | ||
python -m nox -s test-${{ matrix.python_version }} | ||
shell: bash | ||
|
||
- name: Submit coverage results | ||
env: | ||
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }} | ||
run: | | ||
pip install coveralls | ||
coveralls |