[codecov] use pytest and upload all data

- pytest not coverage
- fixed not working linux upload
- pip install -e . or it won't work
- don't run tests twice in travis
- don't ignore init files
- codecov target to 30
This commit is contained in:
back-to 2018-02-26 17:30:38 +01:00
parent 3b7dae75d9
commit 625908a5a3
No known key found for this signature in database
GPG Key ID: 476EB48A8967E369
5 changed files with 13 additions and 13 deletions

View File

@ -5,10 +5,9 @@ source =
[report]
omit =
*/python?.?/*
*__init__*
src/streamlink/packages/*
src/streamlink_cli/packages/*
src/streamlink/_version.py
exclude_lines =
pragma: no cover

3
.gitignore vendored
View File

@ -27,6 +27,9 @@ lib/
local/
share/
pip-selfcheck.json
.pytest_cache/
# coverage
.coverage
coverage.xml
htmlcov

View File

@ -13,17 +13,16 @@ matrix:
- python: '3.7-dev'
before_install:
- pip install --disable-pip-version-check --upgrade pip
- pip install --disable-pip-version-check --upgrade pip setuptools
- pip install -r dev-requirements.txt
- pip install pycountry
- pip install pycountry
- pip install -r docs-requirements.txt
install:
- python setup.py install
- pip install -e .
script:
- python -m pytest tests/
- coverage run -m pytest tests/
- pytest --cov
# test building the docs
- if [[ $BUILD_DOCS == 'yes' ]]; then make --directory=docs html; fi
- if [[ $BUILD_INSTALLER == 'yes' ]]; then ./script/makeinstaller.sh; fi

View File

@ -40,13 +40,13 @@ install:
# install dev requirements, for testing, etc.
- "pip install -r dev-requirements.txt"
- "pip install pycountry"
- "build.cmd %PYTHON%\\python.exe -m pip install ."
- "pip install pycountry"
- "build.cmd %PYTHON%\\python.exe -m pip install -e ."
build: off
test_script:
- "build.cmd %PYTHON%\\python.exe -m coverage run setup.py test"
- "build.cmd %PYTHON%\\python.exe -m pytest --cov"
after_test:
- rm -rf tests/coverages

View File

@ -14,7 +14,6 @@ coverage:
status:
changes: false
patch: false
project:
project:
default:
target: 40
target: 30