diff options
author | Emile Anclin <emile.anclin@logilab.fr> | 2010-11-08 14:22:19 +0100 |
---|---|---|
committer | Emile Anclin <emile.anclin@logilab.fr> | 2010-11-08 14:22:19 +0100 |
commit | 5dde56c810b075d027ec3fb9526334b341566b5e (patch) | |
tree | 4cc838ac5c33c72b03a3d7b07dfadf7c770ff0c1 /test/test_func.py | |
parent | 0e3ab7ad09462e411c85a084548b920840ae566d (diff) | |
download | pylint-5dde56c810b075d027ec3fb9526334b341566b5e.tar.gz |
cleanup: we don't support python 2.2 anymore
Diffstat (limited to 'test/test_func.py')
-rw-r--r-- | test/test_func.py | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/test/test_func.py b/test/test_func.py index 5ee2389..8609070 100644 --- a/test/test_func.py +++ b/test/test_func.py @@ -36,7 +36,6 @@ linter.config.persistent = 0 checkers.initialize(linter) linter.global_set_option('required-attributes', ('__revision__',)) -PY23 = sys.version_info >= (2, 3) PY26 = sys.version_info >= (2, 6) @@ -127,18 +126,16 @@ class TestTests(testlib.TestCase): @testlib.tag('coverage') def test_exhaustivity(self): # skip fatal messages - todo = [msgid for msgid in linter._messages.keys() if msgid[0] != 'F'] - for msgid in test_reporter.message_ids.keys(): + todo = [msgid for msgid in linter._messages if msgid[0] != 'F'] + for msgid in test_reporter.message_ids: try: todo.remove(msgid) except ValueError: continue todo.sort() if PY26: - self.assertEqual(todo, ['E0503', 'E1122', 'I0001']) - elif PY23: - self.assertEqual(todo, ['E0503', 'I0001']) - else: # python < 2.3 + self.assertEqual(todo, ['E1122', 'I0001']) + else: self.assertEqual(todo, ['I0001']) #bycat = {} @@ -181,9 +178,6 @@ def make_tests(filter_rgx): is_to_run = lambda x: 1 tests = [] for module_file, messages_file in get_tests_info('func_', '.py'): - # skip those tests with python >= 2.3 since py2.3 detects them by itself - if PY23 and module_file == "func_unknown_encoding.py": #"func_nonascii_noencoding.py"): - continue pyrestr = module_file.rsplit('_py', 1)[-1][:-3] if pyrestr.isdigit(): # '24', '25'... if sys.version_info < tuple([int(i) for i in pyrestr]): |