From 3fb15b98ff4dd41a47d1c83dc923552926816b36 Mon Sep 17 00:00:00 2001 From: Fridolin Glatter Date: Fri, 22 Nov 2024 15:22:07 +0100 Subject: [PATCH] Exclude if TYPE_CHECKING from coverage --- pyproject.toml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pyproject.toml b/pyproject.toml index 957587e9..6d729319 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -153,6 +153,12 @@ ignore = ["B008"] [tool.ruff.lint.mccabe] max-complexity = 10 +[tool.coverage.report] +exclude_also = [ + # Imports only used by type checkers + "if TYPE_CHECKING:", +] + [tool.poetry-dynamic-versioning] enable = true style = "pep440"