From 0ea80aa627b5f8f052143f5c39563762744356b1 Mon Sep 17 00:00:00 2001 From: Sylvain Th?nault Date: Tue, 6 Aug 2013 14:01:03 +0200 Subject: [test] move out python >= 2.7 specific part --- test/input/func_noerror_defined_and_used_on_same_line.py | 3 --- test/input/func_noerror_defined_and_used_on_same_line_py27.py | 5 +++++ 2 files changed, 5 insertions(+), 3 deletions(-) create mode 100644 test/input/func_noerror_defined_and_used_on_same_line_py27.py diff --git a/test/input/func_noerror_defined_and_used_on_same_line.py b/test/input/func_noerror_defined_and_used_on_same_line.py index a6a869f..71e67b9 100644 --- a/test/input/func_noerror_defined_and_used_on_same_line.py +++ b/test/input/func_noerror_defined_and_used_on_same_line.py @@ -28,6 +28,3 @@ FUNC3 = lambda (a, b) : a != b # test http://www.logilab.org/ticket/6954: with open('f') as f: print(f.read()) - -with open('f') as f, open(f.read()) as g: - print g.read() diff --git a/test/input/func_noerror_defined_and_used_on_same_line_py27.py b/test/input/func_noerror_defined_and_used_on_same_line_py27.py new file mode 100644 index 0000000..5a75722 --- /dev/null +++ b/test/input/func_noerror_defined_and_used_on_same_line_py27.py @@ -0,0 +1,5 @@ +#pylint: disable=C0111,C0321 +"""pylint complains about 'index' being used before definition""" + +with open('f') as f, open(f.read()) as g: + print g.read() -- cgit v1.2.1