Skip to content

Commit

Permalink
Drop support for python setup.py test.
Browse files Browse the repository at this point in the history
  • Loading branch information
Michael Howitz committed Dec 10, 2019
1 parent 5a47553 commit 9a9879b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 20 deletions.
2 changes: 1 addition & 1 deletion CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
4.5 (unreleased)
================

- Nothing changed yet.
- Drop support for ``python setup.py test``.


4.4 (2019-12-10)
Expand Down
21 changes: 2 additions & 19 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,28 +14,13 @@
"""zope.browserresource setup
"""
import os
import sys
from setuptools import setup, find_packages


def read(*rnames):
with open(os.path.join(os.path.dirname(__file__), *rnames)) as f:
return f.read()

def test_suite():
# use the zope.testrunner machinery to find all the
# test suites we've put under ourselves
from zope.testrunner.options import get_options
from zope.testrunner.find import find_suites
from unittest import TestSuite
here = os.path.abspath(os.path.dirname(sys.argv[0]))
args = sys.argv[:]
src = os.path.join(here, 'src')
defaults = ['--test-path', src]
options = get_options(args, defaults)
suites = list(find_suites(options))
return TestSuite(suites)


long_description = read('README.rst') + '\n\n' + read('CHANGES.rst')

Expand All @@ -55,6 +40,7 @@ def test_suite():
author='Zope Foundation and Contributors',
author_email='zope-dev@zope.org',
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Web Environment',
'Intended Audience :: Developers',
'License :: OSI Approved :: Zope Public License',
Expand All @@ -77,8 +63,6 @@ def test_suite():
license='ZPL 2.1',
packages=find_packages('src'),
package_dir={'': 'src'},
test_suite='__main__.test_suite',
tests_require=TESTS_REQUIRE,
namespace_packages=['zope'],
include_package_data=True,
install_requires=[
Expand All @@ -101,5 +85,4 @@ def test_suite():
'repoze.sphinx.autointerface',
],
},
zip_safe=False,
)
zip_safe=False)

0 comments on commit 9a9879b

Please sign in to comment.