On Wed, 11 Sep 2013, Jonathan Hartley wrote:
[...]
I've seen it done in a special "coding style test suite" (that gets run
along with all the other tests). Slightly nicer than a push hook IMO
because you see it earlier and because it works the same way as all your
other automated tests of your code. There was a bit of special code so
that you got one failure per coding style violation I think (including one
per missing copyright statement), but those are bonus points.
Maybe somebody has written a test runner plugin that does that? My quick
searches didn't turn one up, though there is this, which could easily be
adapted (not a plugin, and looks like it wants to be)
http://stackoverflow.com/questions/12227443/is-there-a-plugin-for-pylint-and-pyflakes-for-nose-tests
John
_______________________________________________
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk
I don't think it should be a test runner plugin, so much as just a test.
Maybe a big common utility function (in a pypi package) which a tiny custom
test function can then call to parametrize it for your project.
That works. The reason I suggested a plugin was so that plugin hooks can
give the coding style check function the modules (and scripts) on which to
operate.
John
_______________________________________________
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk