File tree Expand file tree Collapse file tree 3 files changed +16
-2
lines changed Expand file tree Collapse file tree 3 files changed +16
-2
lines changed Original file line number Diff line number Diff line change 35
35
pip install --quiet pep8-naming
36
36
flake8 --config "$GITHUB_WORKSPACE/libraries/compile-examples/compilesketches/.flake8" --show-source "$GITHUB_WORKSPACE/libraries/compile-examples/compilesketches"
37
37
38
- - name : Run Python unit tests
38
+ - name : Run Python unit tests and report code coverage
39
39
run : |
40
40
export PYTHONPATH="$GITHUB_WORKSPACE/libraries/compile-examples/compilesketches"
41
- pytest "$GITHUB_WORKSPACE/libraries/compile-examples/compilesketches/tests"
41
+ coverage run --source="$GITHUB_WORKSPACE/libraries/compile-examples/compilesketches" --module pytest "$GITHUB_WORKSPACE/libraries/compile-examples/compilesketches/tests"
42
+ # Display code coverage report in workflow run log
43
+ coverage report
44
+
45
+ - name : Upload coverage report to Codecov
46
+ uses : codecov/codecov-action@v1
47
+ with :
48
+ fail_ci_if_error : true
Original file line number Diff line number Diff line change
1
+ coverage :
2
+ range : " 100...100"
3
+ status :
4
+ project :
5
+ default :
6
+ threshold : 0%
Original file line number Diff line number Diff line change 1
1
--requirement ../requirements.txt
2
+ coverage == 5.2.1
2
3
pytest == 5.4.2
3
4
pytest-mock == 3.1.0
You can’t perform that action at this time.
0 commit comments