rich/.github/workflows/pythonpackage.yml

43 lines
1.1 KiB
YAML
Raw Normal View History

2019-12-27 10:10:47 +00:00
name: Test Rich module
2019-12-25 15:27:53 +00:00
2020-07-26 17:29:21 +00:00
on: [pull_request]
2019-12-25 15:27:53 +00:00
jobs:
build:
2020-06-20 17:17:52 +00:00
runs-on: ${{ matrix.os }}
2019-12-25 15:27:53 +00:00
strategy:
matrix:
2020-07-27 16:33:51 +00:00
os: [windows-latest, ubuntu-latest, macos-latest]
2020-06-20 16:54:54 +00:00
python-version: [3.6, 3.7, 3.8]
2019-12-25 15:27:53 +00:00
steps:
2019-12-25 15:37:28 +00:00
- uses: actions/checkout@v1
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v1
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
2020-06-20 17:32:56 +00:00
pip install -r requirements-dev.txt
2020-06-20 16:51:53 +00:00
poetry install
- name: Format check with black
run: |
2020-08-21 09:21:42 +00:00
make format
2019-12-25 15:37:28 +00:00
- name: Typecheck with mypy
run: |
2019-12-27 10:08:22 +00:00
make typecheck
2019-12-25 15:37:28 +00:00
- name: Test with pytest
run: |
2019-12-25 15:57:26 +00:00
pip install .
2020-07-16 17:12:35 +00:00
python -m pytest tests -v --cov=./rich --cov-report=xml:./coverage.xml --cov-report term-missing
2020-07-16 15:19:07 +00:00
2020-07-16 15:48:02 +00:00
- name: Upload code coverage
2020-07-16 16:15:29 +00:00
uses: codecov/codecov-action@v1.0.10
2020-07-16 15:28:59 +00:00
with:
2020-07-16 15:53:41 +00:00
token: ${{ secrets.CODECOV_TOKEN }}
2020-07-16 16:08:40 +00:00
file: ./coverage.xml
2020-07-16 15:28:59 +00:00
name: rich
2020-07-16 16:08:40 +00:00
flags: unittests
env_vars: OS,PYTHON