Skip to content

CI

CI #1357

Workflow file for this run

name: CI
on:
push:
pull_request:
schedule:
- cron: '0 0 * * *' # Once per day at midnight
jobs:
test:
runs-on: macos-latest
strategy:
matrix:
python-version: [3.6, 3.7, 3.8, 3.9, "3.10"]
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install flake8
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
if [ -f test_requirements.txt ]; then pip install -r test_requirements.txt; fi
if [ -f docs_requirements.txt ]; then pip install -r docs_requirements.txt; fi
- name: Install test runner
run: python -m pip install tox
- name: Run tests
run: PY_VERSION=${{ matrix.python-version }} && tox -e py${PY_VERSION//.}
lint:
runs-on: macos-latest
strategy:
matrix:
python-version: [3.6, 3.7, 3.8, 3.9, "3.10"]
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install flake8
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
if [ -f test_requirements.txt ]; then pip install -r test_requirements.txt; fi
if [ -f docs_requirements.txt ]; then pip install -r docs_requirements.txt; fi
- name: Lint with flake8
run: |
flake8 .
docs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [3.8]
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install flake8
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
if [ -f test_requirements.txt ]; then pip install -r test_requirements.txt; fi
if [ -f docs_requirements.txt ]; then pip install -r docs_requirements.txt; fi
- name: Install make
run: |
sudo apt-get install build-essential
- name: Make docs
run: |
cd docs && make html