Skip to content
This repository has been archived by the owner on Jun 20, 2022. It is now read-only.

Commit

Permalink
removed tests from setup
Browse files Browse the repository at this point in the history
  • Loading branch information
stephanelsmith committed Sep 9, 2016
1 parent 2041adb commit d5e201a
Showing 1 changed file with 23 additions and 23 deletions.
46 changes: 23 additions & 23 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,26 +7,26 @@
from codecs import open

from setuptools import setup
from setuptools.command.test import test as TestCommand


class PyTest(TestCommand):
user_options = [('pytest-args=', 'a', "Arguments to pass into py.test")]

def initialize_options(self):
TestCommand.initialize_options(self)
self.pytest_args = []

def finalize_options(self):
TestCommand.finalize_options(self)
self.test_args = []
self.test_suite = True

def run_tests(self):
import pytest

errno = pytest.main(self.pytest_args)
sys.exit(errno)
#from setuptools.command.test import test as TestCommand


#class PyTest(TestCommand):
# user_options = [('pytest-args=', 'a', "Arguments to pass into py.test")]
#
# def initialize_options(self):
# TestCommand.initialize_options(self)
# self.pytest_args = []
#
# def finalize_options(self):
# TestCommand.finalize_options(self)
# self.test_args = []
# self.test_suite = True
#
# def run_tests(self):
# import pytest
#
# errno = pytest.main(self.pytest_args)
# sys.exit(errno)


if sys.argv[-1] == 'publish':
Expand All @@ -45,7 +45,7 @@ def run_tests(self):
]

requires = []
test_requirements = ['pytest>=2.8.0', 'pytest-httpbin==0.0.7', 'pytest-cov']
#test_requirements = ['pytest>=2.8.0', 'pytest-httpbin==0.0.7', 'pytest-cov']

with open('requests/__init__.py', 'r') as fd:
version = re.search(r'^__version__\s*=\s*[\'"]([^\'"]*)[\'"]',
Expand Down Expand Up @@ -89,8 +89,8 @@ def run_tests(self):
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: Implementation :: PyPy'
),
cmdclass={'test': PyTest},
tests_require=test_requirements,
#cmdclass={'test': PyTest},
#tests_require=test_requirements,
extras_require={
'security': ['pyOpenSSL>=0.13', 'ndg-httpsclient', 'pyasn1'],
'socks': ['PySocks>=1.5.6, !=1.5.7'],
Expand Down

0 comments on commit d5e201a

Please sign in to comment.