Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Re-enable test coverage #104

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
54 changes: 54 additions & 0 deletions .coveragerc
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
[run]
branch=True
cover_pylib=False
concurrency=thread
data_file=.coverage
disable_warnings=
trace-changed
module-not-python
module-not-imported
no-data-collected
module-not-measured
# include-ignored
omit =
venv/*
janis_core/tests/*
setup.py
parallel = True
plugins=
include=
janis_core/*
timid = False


[report]

exclude_lines =
pragma: no cover
def __repr__
raise NotImplementedError
if __name__ == .__main__.:
def parse_args
def main
fail_under=0
ignore_errors = False
omit =
venv/*
janis_core/tests/*
setup.py
precision=2
show_missing=False
skip_covered=False
sort=Name

[html]

directory=htmlcov
extra_css=
title=


[xml]

output=coverage.xml
package_depth=99
2 changes: 1 addition & 1 deletion .github/workflows/unit_tests.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Unit Tests

on: [push]
on: [push, pull_request]
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be OK to include pull_request too?


jobs:
build:
Expand Down
6 changes: 2 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -79,10 +79,8 @@ docs/_build/
janis_pipelines.egg-info/
dist/
build/




tests_output/
htmlcov/

\.mypy_cache/
*.egg-info
Expand Down
7 changes: 7 additions & 0 deletions pytest.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
[pytest]
addopts =
--cov
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This line will be picked up by pytest, so it will invoke the pytest-cov plug-in (added to the requirements/tests.txt file).

--doctest-modules
--ignore janis_core/tests/
testpaths =
janis_core
3 changes: 2 additions & 1 deletion requirements/tests.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@ nose
codecov
coverage
requests_mock
pytest
pytest
pytest-cov