mirror of
https://github.com/tbabej/taskwiki.git
synced 2025-08-18 21:33:07 +02:00
Revert "tests: Use explicit coverage tracking"
This reverts commit b00e886142
.
This fixes reporting of coverage by the few tests that run outside of
vim.
The commit that is being reverted doesn't explain why it was committed,
and the git history suggests it was reverted once and then reintroduced
later again. None of those commits explains the why. I can only guess
that the last time this was committed was an attempt to fix coverage
reporting to outside of docker, which it didn't, and additionally it
made coverage gathering less robust (see previous commit). So this is
yet another fix for the inaccurate coverage reporting.
Or maybe it was because `--cov` without `=taskwiki` an argument reports
coverage for tests instead of taskwiki code? Nevermind, I guess, now it
works well.
This commit is contained in:
parent
aa6c0deb00
commit
15ce16f24c
5 changed files with 2 additions and 12 deletions
|
@ -29,7 +29,7 @@ RUN cd /root/.vim/bundle/vimwiki/; git checkout dev
|
|||
|
||||
# Setup taskwiki
|
||||
RUN pip3 install \
|
||||
pytest pytest-xdist \
|
||||
pytest pytest-cov pytest-xdist \
|
||||
coveralls coverage \
|
||||
https://github.com/liskin/vimrunner-python/archive/8c19ff88050c09236e7519425bfae33c687483df.zip
|
||||
ADD requirements.txt requirements.txt
|
||||
|
|
3
Makefile
3
Makefile
|
@ -8,9 +8,8 @@ test:
|
|||
pytest:
|
||||
$(PYTHON) -m pytest -vv $(PYTEST_FLAGS) tests/
|
||||
|
||||
cover-pytest: PYTEST_FLAGS += --cov=taskwiki
|
||||
cover-pytest: pytest
|
||||
coverage combine
|
||||
coverage report
|
||||
if [ "$$TRAVIS" ]; then coveralls; fi
|
||||
|
||||
xvfb-%:
|
||||
|
|
|
@ -24,11 +24,6 @@ endif
|
|||
" Determine the plugin path
|
||||
let s:plugin_path = escape(expand('<sfile>:p:h:h:h'), '\')
|
||||
|
||||
" Run the measure parts first, if desired
|
||||
if exists("g:taskwiki_measure_coverage")
|
||||
execute 'py3file ' . s:plugin_path . '/taskwiki/testcoverage.py'
|
||||
endif
|
||||
|
||||
" Execute the main body of taskwiki source
|
||||
execute g:taskwiki_pyfile . s:plugin_path . '/taskwiki/main.py'
|
||||
|
||||
|
|
|
@ -1,3 +0,0 @@
|
|||
import coverage
|
||||
|
||||
coverage.Coverage(auto_data=True, data_suffix=True).start()
|
|
@ -70,7 +70,6 @@ class IntegrationTest(object):
|
|||
self.command('let g:taskwiki_data_location="{0}"'.format(self.dir))
|
||||
self.command('let g:taskwiki_taskrc_location="{0}"'.format(self.taskrc_path))
|
||||
self.command('let g:vimwiki_list = [{"syntax": "default", "ext": ".txt","path": "%s"}]' % self.dir)
|
||||
self.command('let g:taskwiki_measure_coverage="yes"')
|
||||
self.command('let g:taskwiki_markup_syntax="{0}"'.format(self.markup))
|
||||
|
||||
def setup(self):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue