summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndy McCurdy <andy@andymccurdy.com>2018-12-27 15:33:21 -0800
committerGitHub <noreply@github.com>2018-12-27 15:33:21 -0800
commitc9466a1a9bf29593704c8ca52217c17eb3962b4a (patch)
tree376e0ee4898b99236e601ab91e40e1318d119933
parent1244f6e3f9d38379124622ff4f0371914ce759ae (diff)
parentc6c1269c5c1f55dc7819ec4b1ee208f83e1e9f4a (diff)
downloadredis-py-c9466a1a9bf29593704c8ca52217c17eb3962b4a.tar.gz
Merge pull request #1110 from jdufresne/disutils
Remove outdated distutils fallback
-rw-r--r--setup.py31
1 files changed, 12 insertions, 19 deletions
diff --git a/setup.py b/setup.py
index efe09ba..d8eb9ce 100644
--- a/setup.py
+++ b/setup.py
@@ -1,31 +1,24 @@
#!/usr/bin/env python
import os
import sys
+from setuptools import setup
+from setuptools.command.test import test as TestCommand
from redis import __version__
-try:
- from setuptools import setup
- from setuptools.command.test import test as TestCommand
- class PyTest(TestCommand):
- def finalize_options(self):
- TestCommand.finalize_options(self)
- self.test_args = []
- self.test_suite = True
+class PyTest(TestCommand):
+ def finalize_options(self):
+ TestCommand.finalize_options(self)
+ self.test_args = []
+ self.test_suite = True
- def run_tests(self):
- # import here, because outside the eggs aren't loaded
- import pytest
- errno = pytest.main(self.test_args)
- sys.exit(errno)
+ def run_tests(self):
+ # import here, because outside the eggs aren't loaded
+ import pytest
+ errno = pytest.main(self.test_args)
+ sys.exit(errno)
-except ImportError:
-
- from distutils.core import setup
-
- def PyTest(x):
- x
f = open(os.path.join(os.path.dirname(__file__), 'README.rst'))
long_description = f.read()