summaryrefslogtreecommitdiff
path: root/test/test_func.py
diff options
context:
space:
mode:
authorJulien Cristau <julien.cristau@logilab.fr>2013-06-18 15:54:44 +0200
committerJulien Cristau <julien.cristau@logilab.fr>2013-06-18 15:54:44 +0200
commita4a0da15ad6c420af47678abf9194bc95f62468c (patch)
tree876c084dcc8240d0db1711aef1d3debc6a83be2b /test/test_func.py
parentcf8dedb82411a50383aee400406f14ebbeceb6c9 (diff)
downloadpylint-a4a0da15ad6c420af47678abf9194bc95f62468c.tar.gz
test: fix LintTestNonExistentModuleTC for python 3.3
They changed the error message format.
Diffstat (limited to 'test/test_func.py')
-rw-r--r--test/test_func.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/test/test_func.py b/test/test_func.py
index c71ee38..4c75ed6 100644
--- a/test/test_func.py
+++ b/test/test_func.py
@@ -36,9 +36,11 @@ MSG_DIR = join(dirname(abspath(__file__)), 'messages')
# Classes
+quote = "'" if sys.version_info >= (3, 3) else ''
+
class LintTestNonExistentModuleTC(LintTestUsingModule):
module = 'nonexistent'
- _get_expected = lambda self: 'F: 1: No module named nonexistent\n'
+ _get_expected = lambda self: 'F: 1: No module named %snonexistent%s\n' % (quote, quote)
tags = testlib.Tags(('generated','pylint_input_%s' % module))
class LintTestNonExistentFileTC(LintTestUsingFile):
@@ -126,6 +128,9 @@ def suite():
return testlib.TestSuite([unittest.makeSuite(test, suiteClass=testlib.TestSuite)
for test in gen_tests(FILTER_RGX)])
+del LintTestUsingModule
+del LintTestUsingFile
+
if __name__=='__main__':
if '-m' in sys.argv:
MODULES_ONLY = True