diff --git a/.coveragerc b/.coveragerc deleted file mode 100644 index 1553bae2..00000000 --- a/.coveragerc +++ /dev/null @@ -1,13 +0,0 @@ -[run] -branch = True -source = sleepecg -omit = - */examples/* - */setup.py - -[report] -exclude_lines = - pragma: no cover - if __name__ == .__main__.: - @abstractmethod - @abstractclassmethod diff --git a/pyproject.toml b/pyproject.toml index e57cc8c4..68f6cbfb 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -51,6 +51,7 @@ dev = [ # everything needed for development "mypy >= 0.991", "pre-commit >= 2.13.0", "pytest >= 6.2.0", + "pytest-cov >= 6.0.0", "ruff >= 0.4.0", "setuptools >= 56.0.0", ] @@ -85,7 +86,7 @@ build = "cp39-*" # abi3 select = "*" inherit.repair-wheel-command = "append" repair-wheel-command = [ - "pipx run abi3audit --strict --report {wheel}", + "pipx run abi3audit --strict --report {wheel}", ] [tool.cibuildwheel.linux] @@ -99,9 +100,13 @@ archs = "x86_64 arm64" archs = "AMD64" before-build = "pip install delvewheel" repair-wheel-command = [ - "delvewheel repair -w {dest_dir} {wheel}", + "delvewheel repair -w {dest_dir} {wheel}", ] +[tool.coverage.run] +branch = true +source = ["src/sleepecg"] + [tool.mypy] ignore_missing_imports = true disallow_untyped_defs = true @@ -116,6 +121,7 @@ filterwarnings = [ 'ignore:.*datetime.datetime.utcfromtimestamp\(\):DeprecationWarning', 'ignore:(?s).*Pyarrow:DeprecationWarning', ] +addopts = "--cov" [tool.ruff] line-length = 92