Skip to content

Commit

Permalink
Merge 440e216 into b0fcef7
Browse files Browse the repository at this point in the history
  • Loading branch information
thomasyu888 committed Feb 2, 2021
2 parents b0fcef7 + 440e216 commit 2f8b99d
Showing 1 changed file with 31 additions and 9 deletions.
40 changes: 31 additions & 9 deletions .github/workflows/pythonapp.yml
Expand Up @@ -21,7 +21,7 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install flake8 pytest pytest-cov
pip install flake8 pytest coveralls
pip install .
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
- name: Lint with flake8
Expand All @@ -32,11 +32,33 @@ jobs:
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
- name: Test with pytest
run: |
pytest tests/ --doctest-modules --cov=challengeutils --cov-report=html
- name: Upload pytest test results
uses: actions/upload-artifact@master
with:
name: pytest-results-${{ matrix.python-version }}
path: htmlcov
# Use always() to always run this step to publish test results when there are test failures
if: ${{ always() }}
pytest tests
# - name: Upload pytest test results
# uses: actions/upload-artifact@master
# with:
# name: pytest-results-${{ matrix.python-version }}
# path: htmlcov
# # Use always() to always run this step to publish test results when there are test failures
# if: ${{ always() }}
- name: Prepare environment for coveralls
run: |
echo "PYTHON_ENV=$(echo py${{ matrix.python-version }} | tr -d .)" >> $GITHUB_ENV
- name: Coveralls Parallel
env:
COVERALLS_FLAG_NAME: ${{ env.PYTHON_ENV }}
COVERALLS_PARALLEL: true
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
coveralls --service=github
finish-coveralls:
needs: build
runs-on: ubuntu-latest
container: python:3-slim
steps:
- name: Finish Coveralls Parallel
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
pip3 install --upgrade coveralls
coveralls --finish

0 comments on commit 2f8b99d

Please sign in to comment.