Is there a way to make flake8 consider only those files that are tracked in
git?
I have other untracked files in my core dir and flake8 generates warnings
related to such files which are actually out of scope.
That would be appreciated.
Thanks
Mpaa
On Tue, Aug 19, 2014 at 10:39 AM, Antoine Musso <hashar+wmf(a)free.fr> wrote:
Le 18/08/2014 17:48, John Mark Vandenberg a écrit :
To run only the tests which are run by jenkins,
even without a
user-config.py file, use
PYWIKIBOT2_NO_USER_CONFIG=1 nosetests -a "!site,!net"
As an alternative, one can use tox which create virtualenv on the fly
and takes care of installing dependencies and executing the proper command.
pip install tox
tox
tox -l shows a list of predefined envs that are executed by default:
flake8 # linter
flake8-docstrings # pep257 docstring linter
py26 # run test command under python 2.6
py27 # same but with python 2.7
More can be found in the tox.ini file, such as 'nose'.
If you only want to execute the flake8:
tox -e flake8
For nose:
tox -e nose
Jenkins uses exactly that, so your setup should match exactly what it runs.
There is a few more details at:
https://www.mediawiki.org/wiki/Continuous_integration/Tutorials/Test_your_p…
--
Antoine "hashar" Musso
_______________________________________________
Pywikipedia-l mailing list
Pywikipedia-l(a)lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikipedia-l