Update tests to be py.test

pull/29/head
Richard Harding 10 years ago
parent d7038a0845
commit c1e2e529a9

@ -11,4 +11,4 @@ install:
- python setup.py install
- pip install -r requirements.txt --use-mirrors
# command to run tests
script: nosetests tests
script: p.test -q --tb native -s tests

@ -3,17 +3,21 @@ WD := $(shell pwd)
PY := bin/python
PIP := bin/pip
PEP8 := bin/pep8
NOSE := bin/nosetests
PYTEST := bin/py.test
# ###########
# Tests rule!
# ###########
.PHONY: test
test: venv develop $(NOSE)
$(NOSE) -s tests
test: venv develop $(PYTEST)
$(PYTEST) -q --tb native -s tests
$(NOSE):
$(PIP) install nose nose-selecttests pep8 pylint coverage
.PHONY: test-coverage
test-coverage: venv develop $(PYTEST)
$(PYTEST) -q --cov breadability tests
$(PYTEST):
$(PIP) install -r requirements.txt
# #######
# INSTALL
@ -42,8 +46,8 @@ lib/python*/site-packages/breadability.egg-link:
# ###########
# Development
# ###########
.PHONY: clean_all
clean_all: clean_venv
.PHONY: clean-all
clean-all: clean_venv
if [ -d dist ]; then \
rm -r dist; \
fi

@ -2,8 +2,8 @@ docopt>=0.6.1,<0.7
chardet
lxml
nose-selecttests
pylint
pytest
pytest-cov
coverage
nose
pylint
pep8

@ -24,10 +24,10 @@ install_requires = [
"lxml>=2.0",
]
tests_require = [
"nose-selecttests",
"pytest",
"pytest-cov",
"coverage",
"pylint",
"nose",
"pep8",
]

Loading…
Cancel
Save