Create python-package.yml
This commit is contained in:
parent
0e90927f0e
commit
6ca70b262c
1 changed files with 38 additions and 0 deletions
38
.github/workflows/python-package.yml
vendored
Normal file
38
.github/workflows/python-package.yml
vendored
Normal file
|
@ -0,0 +1,38 @@
|
|||
name: Python package
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ master ]
|
||||
pull_request:
|
||||
branches: [ master ]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
matrix:
|
||||
python-version: [3.6, 3.7, 3.8]
|
||||
|
||||
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 dependencies
|
||||
run: |
|
||||
python -m pip install --upgrade pip
|
||||
pip install mypy lxml coverage
|
||||
pip install -e .
|
||||
- name: Lint with flake8
|
||||
run: |
|
||||
# stop the build if there are Python syntax errors or undefined names
|
||||
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
|
||||
- name: mypy
|
||||
run: |
|
||||
mypy aioupnp
|
||||
- name: Test with coverage
|
||||
run: |
|
||||
coverage run -m unittest discover -v tests
|
||||
bash <(curl -s https://codecov.io/bash)
|
Loading…
Reference in a new issue