Skip to content
This repository has been archived by the owner on Apr 24, 2024. It is now read-only.

Update README.rst: archived project #55

Update README.rst: archived project

Update README.rst: archived project #55

Workflow file for this run

name: Continuous Integration
on: [push, pull_request]
# push:
# branches: [ master ]
# pull_request:
# branches: [ master ]
jobs:
Linting:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python 3.8
uses: actions/setup-python@v1
with:
python-version: '3.8'
- name: Linting
run: |
pip install pre-commit
pre-commit run --all-files
Tests:
needs: Linting
name: Tests ${{ matrix.python-version }}
runs-on: ubuntu-latest
strategy:
max-parallel: 2
matrix:
python-version: ['3.6', '3.7', '3.8', '3.9']
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Get full python version
id: full-python-version
shell: bash
run: echo ::set-output name=version::$(python -c "import sys; print('-'.join(str(v) for v in sys.version_info))")
# - name: Install poetry
# shell: bash
# run: |
# curl -fsS -o get-poetry.py https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py
# python get-poetry.py -y
# echo "::set-env name=PATH::$HOME/.poetry/bin:$PATH"
- name: Install poetry
shell: bash
run: |
python -m pip install --upgrade pip
python -m pip install --upgrade poetry
- name: Configure poetry
shell: bash
run: poetry config virtualenvs.in-project true
- name: Set up cache
uses: actions/cache@v1
id: cache
with:
path: .venv
key: venv-${{ runner.os }}-${{ steps.full-python-version.outputs.version }}-${{ hashFiles('**/poetry.lock') }}
- name: Ensure cache is healthy
if: steps.cache.outputs.cache-hit == 'true'
shell: bash
run: poetry run pip --version >/dev/null 2>&1 || rm -rf .venv
- name: Install dependencies
shell: bash
run: poetry install
- name: Run pytest
shell: bash
run: poetry run pytest -m 'not integration'