Skip to content

Commit

Permalink
Remove pytest-runner from setup.py (wright-group#937)
Browse files Browse the repository at this point in the history
* Remove pytest-runner from setup.py

* Update docs to use pytest directly, remove unused scripts

* Use pytest directly on travis

* Include pytest-cov on CI

* Install doc requirements on appveyor

* Install doc requirements on travis
  • Loading branch information
ksunden authored Feb 29, 2020
1 parent 9770f1f commit e8966a3
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 47 deletions.
6 changes: 3 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ addons:
- libopenblas-dev
install:
- pip install cython
- pip install .
- pip install -U pytest "coverage<5"
- pip install .[docs]
- pip install -U pytest "coverage<5" pytest-cov
services:
- xvfb
script: python setup.py test
script: pytest
deploy:
provider: pypi
user: __token__
Expand Down
5 changes: 3 additions & 2 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,10 @@ init:
- "%PYTHON%/python -c \"import struct;print(8 * struct.calcsize(\'P\'))\""

install:
- "%PYTHON%\\Scripts\\pip3 install -e ."
- "%PYTHON%\\Scripts\\pip3 install -e .[docs]"
- "%PYTHON%\\Scripts\\pip3 install pytest pytest-cov"

build: false # Not a C# project, build stuff at the test step instead.

test_script:
- "%PYTHON%/python setup.py test"
- "%PYTHON%/python -m pytest"
6 changes: 3 additions & 3 deletions docs/contributing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -32,15 +32,15 @@ Preparing

.. code-block:: bash
$ python setup.py test
$ pytest
Note: On ``*nix`` machines (unfortunately this does not work on Windows),
the tests may be multiprocessed using `pytest-mp <https://github.com/ansible/pytest-mp>`_:

.. code-block:: bash
$ pip install pytest-mp
$ python setup.py test --addopts "--mp"
$ pytest --mp
Contributing
Expand All @@ -60,7 +60,7 @@ Contributing

.. code-block:: bash
$ python setup.py test
$ pytest
#. make your changes, commiting often

Expand Down
2 changes: 0 additions & 2 deletions scripts/headers.sh

This file was deleted.

35 changes: 0 additions & 35 deletions scripts/upload.sh

This file was deleted.

2 changes: 0 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@ def read(fname):
packages=find_packages(exclude=("tests", "tests.*")),
package_data=extra_files,
python_requires=">=3.6",
setup_requires=["pytest-runner"],
tests_require=["pytest", "pytest-cov", "sphinx", "sphinx-gallery==0.1.12", "sphinx-rtd-theme"],
install_requires=[
"h5py",
"imageio",
Expand Down

0 comments on commit e8966a3

Please sign in to comment.