Skip to content

Commit

Permalink
Following coveralls documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
jeffrey-hokanson committed Nov 22, 2020
1 parent f34bf68 commit 526c9d2
Showing 1 changed file with 26 additions and 14 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# This workflow will install Python dependencies, run tests and lint with a variety of Python versions
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions

name: Python package
name: Unit Testing and Coverage for PolyRat

on:
push:
Expand All @@ -10,8 +10,7 @@ on:
branches: [ master ]

jobs:
build:

test:
runs-on: ubuntu-latest
strategy:
matrix:
Expand All @@ -23,20 +22,33 @@ jobs:
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies

- name: Installing Build/Test Dependencies
run: |
python -m pip install --upgrade pip
pip install -U --only-binary=numpy --only-binary=scipy numpy scipy
python setup.py install
# Testing depencies
pip install pytest pytest-cov coveralls
# - 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
# # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
# flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
- name: Test with pytest
- name: Installing PolyRat
run: python setup.py install

- name: Unit Testing
run: |
pytest --cov=polyrat --cov-branch tests/
coveralls
- name: Coveralls Parallel
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.github_token }}
flag-name: run-${{ matrix.test_number }}
parallel: true

finish:
needs: test
runs-on: ubuntu-latest
steps:
- name: Coveralls Finished
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.github_token }}
parallel-finished: true

0 comments on commit 526c9d2

Please sign in to comment.