File tree Expand file tree Collapse file tree 1 file changed +41
-0
lines changed
Expand file tree Collapse file tree 1 file changed +41
-0
lines changed Original file line number Diff line number Diff line change 1+ # Based on
2+ # python-package.yml
3+ # and
4+ # https://medium.com/@wkrzywiec/how-to-write-good-quality-python-code-with-github-actions-2f635a2ab09a
5+
6+ name : Coverage
7+
8+ on :
9+ push :
10+ branches : [ master ]
11+
12+ jobs :
13+ codecov :
14+
15+ runs-on : ubuntu-latest
16+ strategy :
17+ matrix :
18+ python-version : [3.6]
19+
20+ steps :
21+ - uses : actions/checkout@v2
22+ - name : Set up Python ${{ matrix.python-version }}
23+ uses : actions/setup-python@v2
24+ with :
25+ python-version : ${{ matrix.python-version }}
26+ - name : Install dependencies
27+ run : |
28+ python -m pip install --upgrade pip
29+ pip install flake8
30+ if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
31+ - name : Generate coverage report
32+ run : |
33+ pip install coverage
34+ coverage run --source=. -m runtests
35+ coverage xml
36+ - name : Upload coverage to Codecov
37+ uses : codecov/codecov-action@v1
38+ with :
39+ token : ${{ secrets.CODECOV_TOKEN }}
40+ file : ./coverage.xml
41+ flags : unittests
You can’t perform that action at this time.
0 commit comments