summaryrefslogtreecommitdiff
path: root/setup.py
diff options
context:
space:
mode:
authorTimothy Edmund Crosley <timothy.crosley@gmail.com>2018-09-22 22:04:42 -0700
committerGitHub <noreply@github.com>2018-09-22 22:04:42 -0700
commit8e831f364621eaab152bb7b3308a1ed0418f7326 (patch)
treea8f914f01cfde126b1e25681f41c943e5a5c6563 /setup.py
parent1a6dcfe7f2713559211623fbbc276064b77fd034 (diff)
parent4b31b9e1924f8c481f8172c0fddda1c0370d30d7 (diff)
downloadisort-8e831f364621eaab152bb7b3308a1ed0418f7326.tar.gz
Merge pull request #749 from jdufresne/distutils
Drop legacy distutils fallback in setup.py
Diffstat (limited to 'setup.py')
-rwxr-xr-xsetup.py39
1 files changed, 2 insertions, 37 deletions
diff --git a/setup.py b/setup.py
index 9332dae5..5e6757ad 100755
--- a/setup.py
+++ b/setup.py
@@ -1,39 +1,6 @@
#!/usr/bin/env python
-import subprocess
-import sys
-
-try:
- from setuptools import setup
- from setuptools.command.test import test as TestCommand
-
- class PyTest(TestCommand):
- extra_kwargs = {'tests_require': ['pytest', 'mock']}
-
- def finalize_options(self):
- TestCommand.finalize_options(self)
- self.test_args = []
- self.test_suite = True
-
- def run_tests(self):
- import pytest
- sys.exit(pytest.main(self.test_args))
-
-except ImportError:
- from distutils.core import setup, Command
-
- class PyTest(Command):
- extra_kwargs = {}
- user_options = []
-
- def initialize_options(self):
- pass
-
- def finalize_options(self):
- pass
-
- def run(self):
- raise SystemExit(subprocess.call([sys.executable, 'runtests.py']))
+from setuptools import setup
with open('README.rst', 'r') as f:
readme = f.read()
@@ -60,7 +27,6 @@ setup(name='isort',
},
install_requires=['futures; python_version < "3.2"'],
python_requires=">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*",
- cmdclass={'test': PyTest},
keywords='Refactor, Python, Python2, Python3, Refactoring, Imports, Sort, Clean',
classifiers=['Development Status :: 6 - Mature',
'Intended Audience :: Developers',
@@ -78,5 +44,4 @@ setup(name='isort',
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: Implementation :: PyPy',
'Topic :: Software Development :: Libraries',
- 'Topic :: Utilities'],
- **PyTest.extra_kwargs)
+ 'Topic :: Utilities'])