summaryrefslogtreecommitdiff
path: root/testsuite
diff options
context:
space:
mode:
authorAnthony Sottile <asottile@umich.edu>2017-01-24 14:36:04 -0800
committerIan Cordasco <sigmavirus24@users.noreply.github.com>2017-01-24 16:36:03 -0600
commite4312f75d8e589836e080aeeae28aae0a5c7b087 (patch)
treecfe4905faf18cf02c82a3e0c4864fcdddb2c6141 /testsuite
parent30c7c4822db6db1a68672b1d6c6d951eacae4ae6 (diff)
downloadpep8-e4312f75d8e589836e080aeeae28aae0a5c7b087.tar.gz
Don't report E701 for variable annotations (#612)
Diffstat (limited to 'testsuite')
-rw-r--r--testsuite/E90.py2
-rw-r--r--testsuite/python3.py12
2 files changed, 13 insertions, 1 deletions
diff --git a/testsuite/E90.py b/testsuite/E90.py
index 1db3d0e..2c18e9a 100644
--- a/testsuite/E90.py
+++ b/testsuite/E90.py
@@ -8,7 +8,7 @@ while True:
pass
except:
print 'Whoops'
-#: E122 E225 E251 E251 E701
+#: E122 E225 E251 E251
# Do not crash if code is invalid
if msg:
diff --git a/testsuite/python3.py b/testsuite/python3.py
index 8881880..fde4281 100644
--- a/testsuite/python3.py
+++ b/testsuite/python3.py
@@ -1,6 +1,18 @@
#!/usr/bin/env python3
+from typing import ClassVar, List
# Annotated function (Issue #29)
def foo(x: int) -> int:
return x + 1
+
+
+# Annotated variables #575
+CONST: int = 42
+
+
+class Class:
+ cls_var: ClassVar[str]
+
+ def m(self):
+ xs: List[int] = []