<div dir="ltr">Hi,<div><br></div><div>I am trying to gather documentation to help non-commiters test their changes before sending them to review.</div><div><br></div><div>When run locally some tests fail with a lot of errors and is hard for a developer to filter the errors generated by his/her changes.</div>

<div><br></div><div>Ex:</div><div> * twistedchecker </div><div> * pyflakes</div><div> * api-reference</div><div><br></div><div> I have created patches to clean pyflakes and I also plan to start cleaning the api-reference build errors</div>

<div><br></div><div>From information gathered from #twisted-dev it seems that twistedchecker is not maintained and that some of its errors are invalid... so one should not try to fix all its errors.</div><div>... I wander why twistedchecker is still used ?<br>

</div><div><div><br></div><div>I would like to investigate how we can fix api-reference build errors.</div><div><br></div><div>------</div><div><br></div><div>I have created a travis-ci configuration file which can be used as a reference for running tests. It somehow copies the builders observed on <a href="http://buildbot.twistedmatrix.com">buildbot.twistedmatrix.com</a></div>

<div><br></div><div>A sample build result can be found here:</div><div><a href="https://travis-ci.org/chevah/twisted/builds/19803969">https://travis-ci.org/chevah/twisted/builds/19803969</a><br></div><div><br></div><div>
Code changes are here. If you find them useful I can refine them into a public patch.</div>
<div><a href="https://github.com/chevah/twisted/pull/1/files">https://github.com/chevah/twisted/pull/1/files</a><br></div><div><br></div><div>Only python 2.7 and 3.3 builders are enabled... but 2.6 builders can also be enabled.</div>

<div>py-select-gc tests are not enabled since they are very, very slow.</div><div><br></div><div>Running all tests on a single process could take about 1 hour.</div><div>I guess that running only tests with default reactor and then pyflakes/pydoctor on changed files should cover most errors. </div>

<div><br></div><div>A developer should run at least the following tests before sending a patch for review:</div><div><br></div><div> * trial with default reactor</div><div> * pyflakes for changed files</div><div> * pydoctor for changed files</div>

<div><br></div><div>If documentation was changed he/she should also run documentation tests.</div><div><br></div><div>----</div><div><br></div><div>Running pydoctor on my computer takes about 3 minutes... a bit long for my taste.</div>

<div>I hope that pydoctor can be run on a independent python files so that I can create</div><div>a separate linter test which will run pyflakes and pydoctor only on changes files.</div><div>This should provide a big improvements in speed.</div>

<div><br></div><div>I used travis-ci as it provides  an isolated / reference test environment. Once the configuration is ok, it can be translated into tox [1],  private buildbot [2] or custom script to allow developers to run test on their computers. </div>

<div><br></div><div><div>If a Twisted developer has time, I need some help to check the current travis-ci errors and suggest how to fix them.</div></div><div><br></div><div>Thanks!</div><div><br></div><div>[1] <a href="https://github.com/msabramo/python-panci">https://github.com/msabramo/python-panci</a></div>

<div>[2] <a href="https://github.com/isotoma/buildbot_travis">https://github.com/isotoma/buildbot_travis</a></div><div><br></div>-- <br>Adi Roiban
</div></div>