chore: fix a typo (#118) #230
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
name: Test | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
jobs: | |
get-tox-envlist: | |
runs-on: ubuntu-latest | |
outputs: | |
envlist: ${{ steps.generate-tox-envlist.outputs.envlist }} | |
steps: | |
- uses: actions/checkout@v3 | |
- run: | | |
python -m pip install --upgrade pip | |
python -m pip install tox tox-gh-matrix | |
- id: generate-tox-envlist | |
run: python -m tox --gh-matrix | |
build: | |
name: Test ${{ matrix.tox.name }} | |
runs-on: ubuntu-latest | |
needs: get-tox-envlist | |
strategy: | |
fail-fast: false | |
matrix: | |
tox: ${{ fromJSON(needs.get-tox-envlist.outputs.envlist) }} | |
# Service containers to run with `container-job` | |
services: | |
# Label used to access the service container | |
redis: | |
# Docker Hub image | |
image: redis | |
# Set health checks to wait until redis has started | |
options: >- | |
--health-cmd "redis-cli ping" | |
--health-interval 10s | |
--health-timeout 5s | |
--health-retries 5 | |
ports: | |
# Maps port 6379 on service container to the host | |
- 6379:6379 | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Setup Python ${{ matrix.tox.python.version }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.tox.python.spec }} | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
python -m pip install --upgrade tox | |
- name: Tox tests | |
run: python -m tox -v -e ${{ matrix.tox.name }} | |
- name: Install codecov | |
run: python -m pip install codecov | |
- name: Upload coverage | |
run: python -m codecov --name "Python ${{ matrix.tox.python.spec }}" |