mirror of https://github.com/microsoft/autogen.git
code coverage (#79)
* add codecov.yml * change tests to test * condition * windows * install coverage * remove conditions * revert remove conditions * check build failure * code coverage * Revert "check build failure" This reverts commit bc06b3f961d05c923c2974451961f5c252c9e042. * del codecov.yml Co-authored-by: Chi Wang (MSR) <chiw@microsoft.com> Co-authored-by: Chi Wang <wang.chi@microsoft.com> Co-authored-by: Eric Zhu <ekzhu@users.noreply.github.com>
This commit is contained in:
parent
730fd14ef6
commit
3e991e4352
|
@ -2,4 +2,4 @@
|
|||
branch = True
|
||||
source = flaml
|
||||
omit =
|
||||
*tests*
|
||||
*test*
|
|
@ -7,7 +7,7 @@ on:
|
|||
push:
|
||||
branches: ['main']
|
||||
pull_request:
|
||||
branches: ['*']
|
||||
branches: ['main']
|
||||
|
||||
jobs:
|
||||
build:
|
||||
|
@ -49,13 +49,17 @@ jobs:
|
|||
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
|
||||
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
|
||||
- name: Test with pytest
|
||||
if: ${{ matrix.python-version != '3.7' || matrix.os == 'macos-latest' }}
|
||||
run: |
|
||||
pytest test
|
||||
- name: Coverage
|
||||
if: ${{ matrix.python-version == '3.7' && matrix.os != 'macos-latest' }}
|
||||
run: |
|
||||
pip install coverage
|
||||
coverage run -a -m pytest test
|
||||
coverage xml
|
||||
- name: Upload coverage to Codecov
|
||||
if: ${{ matrix.python-version == '3.7' && matrix.os != 'macos-latest' }}
|
||||
uses: codecov/codecov-action@v1
|
||||
with:
|
||||
file: ./coverage.xml
|
||||
|
|
Loading…
Reference in New Issue