summaryrefslogtreecommitdiff
path: root/numpy/tests/test_typing.py
diff options
context:
space:
mode:
authorBas van Beek <b.f.van.beek@vu.nl>2020-09-01 22:27:05 +0200
committerBas van Beek <b.f.van.beek@vu.nl>2020-09-01 22:27:05 +0200
commitb53bd5a06284bcd417e1b557e5515cbef9083b2c (patch)
tree9a43580a05124c5e2b1df253cd9cf784eab09a81 /numpy/tests/test_typing.py
parentc9bb44b2e1685a831c670913d1963365c7cdd50a (diff)
downloadnumpy-b53bd5a06284bcd417e1b557e5515cbef9083b2c.tar.gz
TST: Don't run typing tests on lines that are commented out
Addresses https://github.com/numpy/numpy/pull/17214#discussion_r481239468
Diffstat (limited to 'numpy/tests/test_typing.py')
-rw-r--r--numpy/tests/test_typing.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/numpy/tests/test_typing.py b/numpy/tests/test_typing.py
index 04ea3c64d..32342d321 100644
--- a/numpy/tests/test_typing.py
+++ b/numpy/tests/test_typing.py
@@ -89,7 +89,7 @@ def test_fail(path):
for i, line in enumerate(lines):
lineno = i + 1
- if " E:" not in line and lineno not in errors:
+ if line.startswith('#') or (" E:" not in line and lineno not in errors):
continue
target_line = lines[lineno - 1]