43 lines
1.3 KiB
YAML
43 lines
1.3 KiB
YAML
name: Tests
|
|
|
|
on: [pull_request]
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ${{ matrix.os }}
|
|
strategy:
|
|
matrix:
|
|
python: [3.6, 3.7, 3.8, 3.9]
|
|
os: [ubuntu-18.04, windows-2016]
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- name: Set up Python ${{ matrix.python }}
|
|
uses: actions/setup-python@v1
|
|
with:
|
|
python-version: ${{ matrix.python }}
|
|
- name: Setup VC
|
|
uses: ilammy/msvc-dev-cmd@v1
|
|
if: contains(matrix.os, 'windows')
|
|
- name: Install CMake
|
|
if: contains(matrix.os, 'ubuntu')
|
|
run: |
|
|
CMAKE_VERSION=3.17.3
|
|
curl -sSL https://github.com/Kitware/CMake/releases/download/v$CMAKE_VERSION/cmake-$CMAKE_VERSION-Linux-x86_64.tar.gz | tar xz
|
|
sudo cp -rT cmake-$CMAKE_VERSION-Linux-x86_64 /usr/local
|
|
rm -rf cmake-$CMAKE_VERSION-Linux-x86_64
|
|
- name: Install dependencies
|
|
run: |
|
|
cmake --version
|
|
python -m pip install --upgrade setuptools pip wheel
|
|
python -m pip install poetry tox-gh-actions
|
|
- name: Test with tox
|
|
run: |
|
|
tox
|
|
- name: Upload coverage reports to Codecov
|
|
uses: codecov/codecov-action@v1
|
|
with:
|
|
token: ${{ secrets.CODECOV_TOKEN }}
|
|
flags: unittests
|
|
name: Python ${{ matrix.python }} on ${{ matrix.os }}
|
|
fail_ci_if_error: false
|