Skip to content

Caesar r_max

Caesar r_max #209

Workflow file for this run

name: Run tests
on:
schedule:
- cron: '19 3 * * 1-5'
push:
pull_request:
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Run Black
uses: psf/black@stable
- name: Set up Python environment
uses: actions/setup-python@v4
with:
python-version: "3.9"
- name: Run flake8
uses: py-actions/flake8@v2
- name: Install mypy
run: pip install mypy
- name: Install types
run: mypy --install-types --non-interactive
- name: Run mypy
run: mypy
build:
needs: lint
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [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: Cache pip
uses: actions/cache@v3
with:
# This path is specific to Ubuntu
path: ~/.cache/pip
# Look to see if there is a cache hit for the corresponding requirements file
key: ${{ runner.os }}-pip-${{ hashFiles('requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-${{ runner.os }}-
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install flake8 pytest
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
if [ -f optional_requirements.txt ]; then pip install -r optional_requirements.txt; fi
pip install -e .
- name: Test with pytest
run: |
pytest