mirror of
https://github.com/python-telegram-bot/python-telegram-bot.git
synced 2024-12-22 14:35:00 +01:00
Turn on branch coverage (#790)
* Run pre commit hook tests on all platforms TEMPORARILY * Use os.system instead of subprocess.call * Turn on branch coverage * Let's try this then * More testing! * Update test_meta.py
This commit is contained in:
parent
d7929a8de4
commit
8cda3f7a71
3 changed files with 7 additions and 4 deletions
|
@ -34,4 +34,5 @@ script:
|
|||
- pytest -v --cov=telegram
|
||||
|
||||
after_success:
|
||||
coveralls
|
||||
- coverage combine
|
||||
- coveralls
|
|
@ -26,8 +26,10 @@ filterwarnings =
|
|||
ignore::DeprecationWarning
|
||||
|
||||
[coverage:run]
|
||||
branch = False
|
||||
branch = True
|
||||
source = telegram
|
||||
parallel = True
|
||||
concurrency = thread, multiprocessing
|
||||
omit =
|
||||
tests/
|
||||
telegram/__main__.py
|
||||
|
|
|
@ -26,7 +26,7 @@ import pytest
|
|||
|
||||
def call_pre_commit_hook(hook_id):
|
||||
__tracebackhide__ = True
|
||||
return subprocess.call(['pre-commit', 'run', '--all-files', hook_id])
|
||||
return os.system(' '.join(['pre-commit', 'run', '--all-files', hook_id]))
|
||||
|
||||
|
||||
@pytest.mark.parametrize('hook_id', argvalues=('yapf', 'flake8', 'pylint'))
|
||||
|
@ -39,4 +39,4 @@ def test_pre_commit_hook(hook_id):
|
|||
|
||||
|
||||
def test_build():
|
||||
assert subprocess.call(['python', 'setup.py', 'bdist_dumb']) == 0
|
||||
assert os.system('python setup.py bdist_dumb') == 0
|
||||
|
|
Loading…
Reference in a new issue