diff --git a/no-coverage.patch b/no-coverage.patch new file mode 100644 index 0000000..4d0015c --- /dev/null +++ b/no-coverage.patch @@ -0,0 +1,45 @@ +--- + pyproject.toml | 22 ---------------------- + 1 file changed, 22 deletions(-) + +--- a/pyproject.toml ++++ b/pyproject.toml +@@ -40,9 +40,7 @@ ruff = "0.3.2" + mypy = "1.9.0" + + [tool.poetry.group.test.dependencies] +-coverage = "7.4.4" + pytest = "8.1.1" +-pytest-cov = "4.1.0" + + [tool.poetry.group.docs] + optional = true +@@ -65,28 +63,8 @@ changelogging = "1.4.1" + line-length = 100 + + [tool.pytest.ini_options] +-addopts = "--cov named" + testpaths = ["tests"] + +-[tool.coverage.run] +-source = ["named"] +- +-[tool.coverage.report] +-ignore_errors = true +-exclude_lines = [ +- "pragma: never", +- "pragma: no cover", +- "if TYPE_CHECKING", +- "@overload", +- "@required", +- "raise NotImplementedError", +- "raise AssertionError", +- "def __repr__", +-] +- +-[tool.coverage.html] +-directory = "coverage" +- + [tool.mypy] + strict = true + diff --git a/python-named.changes b/python-named.changes index 604717e..06ff3b0 100644 --- a/python-named.changes +++ b/python-named.changes @@ -1,3 +1,13 @@ +------------------------------------------------------------------- +Fri Nov 22 09:51:46 UTC 2024 - Matej Cepl + +- Add no-coverage.patch eliminating coverage measurement. + +------------------------------------------------------------------- +Fri Nov 22 09:12:07 UTC 2024 - ecsos + +- Add %{?sle15_python_module_pythons} + ------------------------------------------------------------------- Thu Nov 14 09:15:36 UTC 2024 - Dirk Müller diff --git a/python-named.spec b/python-named.spec index 7118b27..1c44178 100644 --- a/python-named.spec +++ b/python-named.spec @@ -16,6 +16,7 @@ # +%{?sle15_python_module_pythons} Name: python-named Version: 1.4.2 Release: 0 @@ -23,9 +24,11 @@ Summary: Named types License: MIT URL: https://github.com/nekitdev/named Source: https://github.com/nekitdev/named/archive/refs/tags/v%{version}.tar.gz#/named-%{version}-gh.tar.gz +# PATCH-FEATURE-OPENSUSE no-coverage.patch mcepl@suse.com +# Don't calculate test coverage +Patch0: no-coverage.patch BuildRequires: %{python_module pip} BuildRequires: %{python_module poetry-core >= 1.9.0} -BuildRequires: %{python_module pytest-cov} BuildRequires: %{python_module pytest} BuildRequires: %{python_module typing-extensions} BuildRequires: fdupes