From 047fda53829202b9fe6b1e38d7ea1fe1216efd87 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ezequiel=20P=C3=A1ssaro?= Date: Wed, 9 Jun 2021 17:50:30 -0300 Subject: [PATCH 1/9] add codecov.yml --- .codecov.yml | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 .codecov.yml diff --git a/.codecov.yml b/.codecov.yml new file mode 100644 index 00000000000..617fa2dbfe6 --- /dev/null +++ b/.codecov.yml @@ -0,0 +1,9 @@ +coverage: + range: 60..100 + round: down + precision: 2 + status: + project: + default: + target: auto + threshold: 0.5% From 9ab1d608ec1b3262ed27560d11cae1020d9a1b59 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ezequiel=20P=C3=A1ssaro?= Date: Wed, 9 Jun 2021 18:00:26 -0300 Subject: [PATCH 2/9] enable patch report again --- .codecov.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.codecov.yml b/.codecov.yml index 617fa2dbfe6..083ec8641cb 100644 --- a/.codecov.yml +++ b/.codecov.yml @@ -7,3 +7,4 @@ coverage: default: target: auto threshold: 0.5% + #patch: off From d39c1acd58daa93809f56bb833c86a8648bf98e3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ezequiel=20P=C3=A1ssaro?= Date: Wed, 9 Jun 2021 18:18:10 -0300 Subject: [PATCH 3/9] rewrite coveragerc with wildcards --- .coveragerc | 60 +++++++++++++++++++++-------------------------------- 1 file changed, 24 insertions(+), 36 deletions(-) diff --git a/.coveragerc b/.coveragerc index 78b086c6ffa..d3c684695b7 100644 --- a/.coveragerc +++ b/.coveragerc @@ -2,48 +2,36 @@ source = tardis [report] +# Regexes for lines to exclude from consideration exclude_lines = - # Have to re-enable the standard pragma - pragma: no cover + # Have to re-enable the standard pragma + pragma: no cover - # Don't complain about packages we have installed - except ImportError + # Don't complain about missing debug-only code: + def __repr__ + if self\.debug - # Don't complain if tests don't hit assertions - raise AssertionError - raise NotImplementedError + # Don't complain if tests don't hit defensive assertion code: + raise AssertionError + raise NotImplementedError - # Don't complain about script hooks - def main\(.*\): - - # Ignore branches that don't pertain to this version of Python - pragma: py{ignore_python_version} + # Don't complain if non-runnable code isn't run: + if 0: + if __name__ == .__main__.: omit = + *__init__* + *_astropy_init* + *version* + *tests* + *conftest* + *setup_package* - # Tests should not appear in coveralls - tardis/tests/* - tardis/plasma/tests/* - tardis/model/tests/* - tardis/montecarlo/tests/* - tardis/simulation/tests/* - tardis/io/tests/* - - # Omit all setup_package.py files - tardis/tests/setup_package.py - tardis/plasma/setup_package.py - tardis/montecarlo/setup_package.py - tardis/model/setup_package.py - tardis/simulation/setup_package.py - tardis/io/setup_package.py - - tardis/gui/* - tardis/stats/* - tardis/analysis.py - - # Omit all version and __init__.py files - *version* - *__init__* - *_astropy_init* + tardis/gui/* + tardis/stats/* + tardis/analysis.py +ignore_errors = True +[html] +directory = coverage_html_report From fc1f1266e2bb934138206f7f9664119f6292b550 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ezequiel=20P=C3=A1ssaro?= Date: Wed, 9 Jun 2021 18:27:44 -0300 Subject: [PATCH 4/9] remove unnecessary lines --- .coveragerc | 4 ---- 1 file changed, 4 deletions(-) diff --git a/.coveragerc b/.coveragerc index d3c684695b7..0f05c1161bc 100644 --- a/.coveragerc +++ b/.coveragerc @@ -1,6 +1,3 @@ -[run] -source = tardis - [report] # Regexes for lines to exclude from consideration exclude_lines = @@ -22,7 +19,6 @@ exclude_lines = omit = *__init__* *_astropy_init* - *version* *tests* *conftest* *setup_package* From 6f89ea6527695cd802aa0554d6b11ac4cff14e62 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ezequiel=20P=C3=A1ssaro?= Date: Wed, 9 Jun 2021 18:35:04 -0300 Subject: [PATCH 5/9] skip scripts folder --- .coveragerc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.coveragerc b/.coveragerc index 0f05c1161bc..8639aaaf5df 100644 --- a/.coveragerc +++ b/.coveragerc @@ -22,10 +22,11 @@ omit = *tests* *conftest* *setup_package* - + + tardis/analysis.py tardis/gui/* + tardis/scripts/* tardis/stats/* - tardis/analysis.py ignore_errors = True From 53ffc88c3dfa398eaff3f704e5130cfedede8c07 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ezequiel=20P=C3=A1ssaro?= Date: Wed, 9 Jun 2021 18:49:09 -0300 Subject: [PATCH 6/9] add version.py --- .coveragerc | 1 + 1 file changed, 1 insertion(+) diff --git a/.coveragerc b/.coveragerc index 8639aaaf5df..b77d150171b 100644 --- a/.coveragerc +++ b/.coveragerc @@ -19,6 +19,7 @@ exclude_lines = omit = *__init__* *_astropy_init* + *version* *tests* *conftest* *setup_package* From fd7818daad9236fb269e2e97aa8dc91f9a4297b9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ezequiel=20P=C3=A1ssaro?= Date: Sat, 12 Jun 2021 16:33:03 -0300 Subject: [PATCH 7/9] add default comment on header --- .coveragerc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.coveragerc b/.coveragerc index b77d150171b..0bab2bddc38 100644 --- a/.coveragerc +++ b/.coveragerc @@ -1,3 +1,5 @@ +# .coveragerc to control coverage.py + [report] # Regexes for lines to exclude from consideration exclude_lines = From 0144a3ef55bf64af382edd9a314403b49ad9c941 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ezequiel=20P=C3=A1ssaro?= Date: Sat, 12 Jun 2021 18:35:10 -0300 Subject: [PATCH 8/9] do not ignore scripts folder --- .coveragerc | 1 - 1 file changed, 1 deletion(-) diff --git a/.coveragerc b/.coveragerc index 0bab2bddc38..8d1c47f6f71 100644 --- a/.coveragerc +++ b/.coveragerc @@ -28,7 +28,6 @@ omit = tardis/analysis.py tardis/gui/* - tardis/scripts/* tardis/stats/* ignore_errors = True From 1a78bf88ac4a164a5948ca9f0002075e0cd07baa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ezequiel=20P=C3=A1ssaro?= Date: Mon, 14 Jun 2021 11:33:24 -0300 Subject: [PATCH 9/9] remove analysis script --- .coveragerc | 1 - 1 file changed, 1 deletion(-) diff --git a/.coveragerc b/.coveragerc index 8d1c47f6f71..5a8c5e23e4e 100644 --- a/.coveragerc +++ b/.coveragerc @@ -26,7 +26,6 @@ omit = *conftest* *setup_package* - tardis/analysis.py tardis/gui/* tardis/stats/*