We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents ef16c84 + 153a0ca commit 9d56f5fCopy full SHA for 9d56f5f
1 file changed
django_coverage_plugin/plugin.py
@@ -120,6 +120,8 @@ def __init__(self, options):
120
121
self.exclude_blocks = options.get("exclude_blocks")
122
123
+ self.exclude_blocks = options.get("exclude_blocks")
124
+
125
self.debug_checked = False
126
127
self.django_template_dir = os.path.normcase(os.path.realpath(
@@ -334,6 +336,12 @@ def lines(self):
334
336
self._excluded.add(token.lineno)
335
337
continue
338
339
+ # Ignore any block token content that has been explcitly
340
+ # excluded in config
341
+ if self.exclude_block_token(token):
342
+ self._excluded.add(token.lineno)
343
+ continue
344
345
if token.contents == "comment":
346
comment = True
347
if token.contents.startswith("end"):
0 commit comments