Skip to content

Commit

Permalink
py.test: rerun and print warnings by default
Browse files Browse the repository at this point in the history
  • Loading branch information
raphaelm committed Sep 27, 2016
1 parent 3bc2ddf commit b6a3497
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 3 deletions.
3 changes: 0 additions & 3 deletions doc/development/setup.rst
Expand Up @@ -96,9 +96,6 @@ Before you check in your code into git, always run the static checkers and unit
package ``pytest-xdist`` using ``pip install pytest-xdist`` and then run ``py.test -n NUM`` with
``NUM`` being the number of threads you want to use.

.. note:: We currently have some flaky tests that we haven't yet been able to debug. If you just run
``py.test --rerun 5`` they'll be rerun and only reported as failures if they fail repeatedly.

It is a good idea to put this command into your git hook ``.git/hooks/pre-commit``,
for example::

Expand Down
1 change: 1 addition & 0 deletions src/pytest.ini
@@ -1,2 +1,3 @@
[pytest]
DJANGO_SETTINGS_MODULE=tests.settings
addopts =--rerun 3 -rw
1 change: 1 addition & 0 deletions src/requirements/dev.txt
Expand Up @@ -12,3 +12,4 @@ pytest-django
isort
pytest-mock
pytest-rerunfailures
pytest-warnings

0 comments on commit b6a3497

Please sign in to comment.