comparison .github/workflows/python-publish.yml @ 25:c75ee64c812c

add tests job
author Dennis Concepcion Martin <dennisconcepcionmartin@gmail.com>
date Sun, 21 Nov 2021 18:38:18 +0100
parents d1f527020d54
children 30535f42d0ff
comparison
equal deleted inserted replaced
24:139c77ea99b7 25:c75ee64c812c
17 python-version: '3.x' 17 python-version: '3.x'
18 - name: Install dependencies 18 - name: Install dependencies
19 run: | 19 run: |
20 python -m pip install --upgrade pip 20 python -m pip install --upgrade pip
21 pip install build 21 pip install build
22 python -m pip install flake8
23 if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
24 - name: Lint with flake8
25 run: |
26 # stop the build if there are Python syntax errors or undefined names
27 flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
28 # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
29 flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
30 - name: Test
31 run: python -m unittest discover
22 - name: Build package 32 - name: Build package
23 run: python -m build 33 run: python -m build
24 - name: Publish package 34 - name: Publish package
25 uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29 35 uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29
26 with: 36 with: