diff options
author | Claudiu Popa <pcmanticore@gmail.com> | 2015-12-02 16:47:52 +0200 |
---|---|---|
committer | Claudiu Popa <pcmanticore@gmail.com> | 2015-12-02 16:47:52 +0200 |
commit | 14a9fd22e78f0386b4ce657b4b220b5177ab9985 (patch) | |
tree | 746b5006acd47d8034dd29fef79469a2518ad1d4 | |
parent | c6ddf9588038ce8e6abdc4719f3e63f1712ca354 (diff) | |
download | pylint-14a9fd22e78f0386b4ce657b4b220b5177ab9985.tar.gz |
Try to register the else-if checker explicitly instead on relying on path assumptions.
-rw-r--r-- | pylint/test/extensions/test_elseif_used.py | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/pylint/test/extensions/test_elseif_used.py b/pylint/test/extensions/test_elseif_used.py index 72dc9f4..991193c 100644 --- a/pylint/test/extensions/test_elseif_used.py +++ b/pylint/test/extensions/test_elseif_used.py @@ -6,9 +6,9 @@ import os.path as osp import unittest from pylint import checkers +from pylint.extensions.check_elif import ElseifUsedChecker from pylint.lint import PyLinter from pylint.reporters import BaseReporter -from pylint.utils import register_plugins class TestReporter(BaseReporter): @@ -27,9 +27,7 @@ class CheckElseIfUsedTC(unittest.TestCase): cls._linter = PyLinter() cls._linter.set_reporter(TestReporter()) checkers.initialize(cls._linter) - plugins_path = osp.join(osp.dirname(osp.abspath(__file__)), os.pardir, - os.pardir, 'extensions') - register_plugins(cls._linter, plugins_path) + cls._linter.register_checker(ElseifUsedChecker(cls._linter)) def test_elseif_message(self): elif_test = osp.join(osp.dirname(osp.abspath(__file__)), 'data', |