name: Test

on:
  push:
    branches: [master]
  pull_request:
    branches: [master]

jobs:
  lint:
    runs-on: ubuntu-latest
    steps:
    - uses: actions/checkout@v2
    - name: Set up Python 3.8
      uses: actions/setup-python@v2
      with:
        # pytype currently doesn't work with python >= 3.9
        python-version: 3.8
    - name: Install tox
      run: pip install tox
    - name: Run style and typing checks
      run: tox -e lint
  test:
    runs-on: ${{ matrix.platform }}
    strategy:
      matrix:
        python-version: [3.6, 3.7, 3.8, 3.9]
        platform: [ubuntu-latest]
    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 tox
      run: pip install tox
    - name: Run the tests
      run: tox -e py

Add Github Actions CI setup
Add Github Actions CI setup

Initially we only run tests on Linux for all the supported pythons from 3.6 through to 3.9.

We also run black and pytype as an independent job
