Skip to content

Commit 0676554

Browse files
author
Jordan Adler
committed
Switch to pytest
1 parent 2954adb commit 0676554

File tree

5 files changed

+6
-68
lines changed

5 files changed

+6
-68
lines changed

.travis.yml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ matrix:
1818
sudo: required # required for Python 3.7 (travis-ci/travis-ci#9069)
1919

2020
install:
21-
- pip install tox
21+
- pip install tox pytest
2222

2323
before_script:
2424
# Run flake8 tests only on Python 2.7 and 3.7...
@@ -30,7 +30,5 @@ before_script:
3030
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics;
3131
fi
3232

33-
# command to run tests, e.g. python setup.py test
34-
3533
script:
3634
- tox

TESTING.txt

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
Currently the tests are passing on OS X and Linux on Python 2.7 and 3.4.
22

3-
The test suite can be run either with:
3+
The test suite can be run with:
44

5-
$ python setup.py test
5+
$ tox
66

7-
which uses the unittest module's test discovery mechanism, or with:
8-
9-
$ py.test
7+
which tests the module under a number of different python versions, where available.

discover_tests.py

Lines changed: 0 additions & 57 deletions
This file was deleted.

setup.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,6 @@
7878
'LICENSE.txt',
7979
'futurize.py',
8080
'pasteurize.py',
81-
'discover_tests.py',
8281
'check_rst.sh',
8382
'TESTING.txt',
8483
],
@@ -177,6 +176,5 @@
177176
include_package_data=True,
178177
python_requires=">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*",
179178
classifiers=CLASSIFIERS,
180-
test_suite = "discover_tests",
181179
**setup_kwds
182180
)

tox.ini

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,5 @@
22
envlist = py27,py34,py35,py36,py37
33

44
[testenv]
5-
commands = python setup.py test
5+
deps = pytest
6+
commands = pytest {posargs}

0 commit comments

Comments
 (0)