How to write unittests for a custom pylint checker? <p>I have written a custom pylint checker <a href="https://github.com/rory/python-pylint-i18n" rel="nofollow">to check for non-i18n'ed strings in python code</a>. I'd like to write some unittests for that code now.</p> <p>But how? I'd like to have tests with python code as a string, which will get passed through my plugin/checker and check the output?</p> <p>I'd rather not write the strings out to temporary files and then invoke the pylint binary on it. Is there a cleaner more robust approach, which only tests my code?</p>