Merge branch 'develop' of https://github.com/hmc-alpaqa/metrinome int… #388
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Coverage | |
on: | |
push: | |
branches: | |
- develop | |
pull_request: | |
branches: | |
- develop | |
jobs: | |
coverage-job: | |
name: Coverage Job | |
runs-on: self-hosted | |
timeout-minutes: 30 | |
steps: | |
- name: Take ownership of repo directory | |
run: echo ${{ secrets.SUDO_PW }} | sudo -S chown -R $USER:$USER /home/gabe/actions-runner/_work/metrinome | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Stop existing docker image | |
run: cd $GITHUB_WORKSPACE/src && make stop-detached || echo continuing | |
- name: Delete existing image | |
run: docker rm detached_repl || echo continuing | |
- name: Run new docker image | |
run: cd $GITHUB_WORKSPACE/src && make run-detached | |
- name: Execute coverage check | |
run: docker exec -w /app/code -e PYTHONDONTWRITEBYTECODE=1 -e MYPY_CACHE_DIR=/dev/null detached_repl make coverage | |
- name: Upload coverage | |
uses: codecov/codecov-action@v1 | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
file: /home/gabe/actions-runner/_work/metrinome/metrinome/src/coverage.xml |