Merge pull request #368 from AltSchool/twine-changes #151
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: [ master ] | |
pull_request: | |
branches: [ master ] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
python-version: [3.7, 3.8, 3.9, "3.10"] | |
dj-version: ["2.2.*", "3.0.*", "3.1.*", "3.2.*", "4.0.*", "4.1.*"] | |
drf-version: ["3.11.*", "3.12.*", "3.13.*"] | |
exclude: | |
- python-version: 3.7 | |
dj-version: '4.0.*' | |
- python-version: 3.7 | |
dj-version: '4.1.*' | |
- dj-version: '4.0.*' | |
drf-version: '3.11.*' | |
- dj-version: '4.1.*' | |
drf-version: '3.11.*' | |
- dj-version: '4.0.*' | |
drf-version: '3.12.*' | |
- dj-version: '4.1.*' | |
drf-version: '3.12.*' | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v2 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install Dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install -r requirements.txt | |
pip install 'django==${{ matrix.dj-version }}' 'djangorestframework==${{ matrix.drf-version }}' | |
- name: Run Tests | |
run: | | |
./runtests.py --fast --coverage -rw | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Python39 | |
uses: actions/setup-python@v2 | |
with: | |
python-version: 3.9 | |
- name: Install Dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install flake8==5.0.4 | |
- name: Lint Code | |
run: | | |
flake8 dynamic_rest tests |