mirror of
https://github.com/django/daphne.git
synced 2025-07-14 18:02:17 +03:00
Run tests on MacOS and Windows too
This commit is contained in:
parent
b96720390f
commit
899a29b56a
33
.github/workflows/tests.yml
vendored
33
.github/workflows/tests.yml
vendored
|
@ -3,20 +3,30 @@ name: Tests
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- master
|
- master
|
||||||
pull_request:
|
pull_request:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
tests:
|
tests:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ${{ matrix.os }}-latest
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
|
os:
|
||||||
|
- macos
|
||||||
|
- windows
|
||||||
|
- ubuntu
|
||||||
python-version:
|
python-version:
|
||||||
- 3.6
|
- 3.6
|
||||||
- 3.7
|
- 3.7
|
||||||
- 3.8
|
- 3.8
|
||||||
- 3.9
|
- 3.9
|
||||||
|
exclude:
|
||||||
|
# Jobs fail on Windows if there's no wheel for twisted
|
||||||
|
- os: windows
|
||||||
|
python-version: 3.8
|
||||||
|
- os: windows
|
||||||
|
python-version: 3.9
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
|
@ -26,11 +36,14 @@ jobs:
|
||||||
python-version: ${{ matrix.python-version }}
|
python-version: ${{ matrix.python-version }}
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
python -m pip install --upgrade pip wheel setuptools tox
|
python -m pip install --upgrade pip wheel setuptools tox tox-factor
|
||||||
- name: Run tox targets for ${{ matrix.python-version }}
|
- name: Set pyversion for tox
|
||||||
run: |
|
run: |
|
||||||
ENV_PREFIX=$(tr -C -d "0-9" <<< "${{ matrix.python-version }}")
|
python -c "import sys; print('::set-output name=PYV::', ''.join([str(x) for x in sys.version_info[:2]]), sep='')"
|
||||||
TOXENV=$(tox --listenvs | grep "^py$ENV_PREFIX" | tr '\n' ',') python -m tox
|
id: pyversion
|
||||||
|
- name: Run tox targets for Python ${{ matrix.python-version }} on ${{ matrix.os }}
|
||||||
|
run: |
|
||||||
|
python -m tox -f py${{ steps.pyversion.outputs.PYV }}-${{ matrix.os }}
|
||||||
|
|
||||||
lint:
|
lint:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
Loading…
Reference in New Issue
Block a user