summaryrefslogtreecommitdiff
path: root/pyflakes/test/harness.py
diff options
context:
space:
mode:
Diffstat (limited to 'pyflakes/test/harness.py')
-rw-r--r--pyflakes/test/harness.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/pyflakes/test/harness.py b/pyflakes/test/harness.py
index d375ea3..b20ac79 100644
--- a/pyflakes/test/harness.py
+++ b/pyflakes/test/harness.py
@@ -16,11 +16,13 @@ class TestCase(unittest.TestCase):
def flakes(self, input, *expectedOutputs, **kw):
tree = ast.parse(textwrap.dedent(input))
- tokens = checker.make_tokens(textwrap.dedent(input))
+ file_tokens = checker.make_tokens(textwrap.dedent(input))
if kw.get('is_segment'):
tree = tree.body[0]
kw.pop('is_segment')
- w = checker.Checker(tree, tokens=tokens, withDoctest=self.withDoctest, **kw)
+ w = checker.Checker(
+ tree, file_tokens=file_tokens, withDoctest=self.withDoctest, **kw
+ )
outputs = [type(o) for o in w.messages]
expectedOutputs = list(expectedOutputs)
outputs.sort(key=lambda t: t.__name__)