Skip to content

Commit

Permalink
Switch to using py.test
Browse files Browse the repository at this point in the history
  • Loading branch information
pfmoore committed Nov 9, 2014
1 parent 0464ff2 commit 8d85918
Show file tree
Hide file tree
Showing 9 changed files with 20 additions and 66 deletions.
4 changes: 2 additions & 2 deletions CONTRIBUTING.rst
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ Now you can make your changes locally.
5. When you're done making changes, check that your changes pass the tests and flake8::

$ flake8 cookiecutter tests
$ python setup.py test
$ py.test
$ tox

6. Commit your changes and push your branch to GitHub::
Expand All @@ -117,7 +117,7 @@ Now you can make your changes locally.

7. Check that the test coverage hasn't dropped::

coverage run --source cookiecutter setup.py test
coverage run --source cookiecutter -m py.test
coverage report -m
coverage html

Expand Down
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,14 @@ lint:
flake8 cookiecutter tests

test:
python setup.py test
py.test

test-all:
tox


coverage:
coverage run --source cookiecutter setup.py test
coverage run --source cookiecutter -m py.test
coverage report -m
coverage html
open htmlcov/index.html
Expand Down
1 change: 0 additions & 1 deletion requirements/base_test.txt

This file was deleted.

7 changes: 0 additions & 7 deletions requirements/test_26.txt

This file was deleted.

4 changes: 0 additions & 4 deletions requirements/test_27.txt

This file was deleted.

3 changes: 0 additions & 3 deletions requirements/test_33.txt

This file was deleted.

3 changes: 0 additions & 3 deletions requirements/test_34.txt

This file was deleted.

36 changes: 16 additions & 20 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,28 +1,24 @@
[tox]
envlist = py26, py27, py33, py34, pypy, flake8
envlist = py26, py27, py33, py34, pypy

[testenv]
commands = py.test tests {posargs}
deps = pytest

[testenv:py26]
deps = -r{toxinidir}/requirements/test_26.txt
commands = coverage run --source cookiecutter setup.py test
deps =
{[testenv]deps}
mock
unittest2
ordereddict
simplejson>2.1

[testenv:py27]
deps = -r{toxinidir}/requirements/test_27.txt
commands = coverage run --source cookiecutter setup.py test
deps =
{[testenv]deps}
mock

[testenv:pypy]
deps = -r{toxinidir}/requirements/test_27.txt
commands = coverage run --source cookiecutter setup.py test

[testenv:py33]
deps = -r{toxinidir}/requirements/test_33.txt
commands = coverage run --source cookiecutter setup.py test

[testenv:py34]
deps = -r{toxinidir}/requirements/test_34.txt
commands = coverage run --source cookiecutter setup.py test

[testenv:flake8]
deps =
flake8
commands =
flake8 cookiecutter
{[testenv]deps}
mock
24 changes: 0 additions & 24 deletions tox_pytest.ini

This file was deleted.

0 comments on commit 8d85918

Please sign in to comment.