File tree Expand file tree Collapse file tree 4 files changed +52
-1
lines changed Expand file tree Collapse file tree 4 files changed +52
-1
lines changed Original file line number Diff line number Diff line change 2
2
3
3
set -e -x
4
4
5
- pytest tests
5
+ coverage run --branch -m pytest tests
6
+ coverage xml
7
+ coverage erase
Original file line number Diff line number Diff line change
1
+ [report]
2
+ # Regexes for lines to exclude from consideration
3
+ exclude_lines =
4
+ # Have to re-enable the standard pragma
5
+ pragma: no cover
6
+ def __repr__
7
+
8
+ # Don't complain about missing debug-only code:
9
+ if self\.debug
10
+
11
+ # Don't complain if tests don't hit defensive assertion code:
12
+ raise AssertionError
13
+ raise NotImplementedError
14
+
15
+ # Don't complain if non-runnable code isn't run:
16
+ if 0:
17
+ if False:
18
+ if __name__ == .__main__.:
19
+
20
+ # Not counting some extra lines which don't need to be counted.
21
+ print
22
+ def setUp
23
+ def test_
24
+ def suite
25
+
26
+ ignore_errors = True
27
+
28
+ omit =
29
+ */build/*
30
+ */doc/*
31
+ */examples/*
32
+ */postprocessing/*
33
+ */test/*
34
+ */setup.py
35
+ setup.py
36
+ */site-packages/*
37
+ azure/functions/_thirdparty/*
38
+ */venv/*
39
+ */.venv/*
40
+ */.env*/*
41
+ */.vscode/*
Original file line number Diff line number Diff line change 29
29
chmod +x .ci/run_tests.sh
30
30
.ci/run_tests.sh
31
31
displayName: 'Run Tests'
32
+ - task : PublishCodeCoverageResults@1
33
+ inputs :
34
+ codeCoverageTool : cobertura
35
+ summaryFileLocation : coverage.xml
36
+ - bash : |
37
+ rm coverage.xml
38
+ displayName: 'Clearing coverage.xml file'
Original file line number Diff line number Diff line change 29
29
'mypy' ,
30
30
'pytest' ,
31
31
'requests==2.*' ,
32
+ 'coverage'
32
33
]
33
34
},
34
35
include_package_data = True ,
You can’t perform that action at this time.
0 commit comments