mirror of
https://github.com/graphql-python/graphene.git
synced 2025-07-27 08:19:45 +03:00
Merge cfd5086ef9
into 9efdf4c46e
This commit is contained in:
commit
6fa69a54bd
|
@ -22,7 +22,7 @@ before_install:
|
|||
install:
|
||||
- |
|
||||
if [ "$TEST_TYPE" = build ]; then
|
||||
pip install -e .[test]
|
||||
pip install -r requirements-dev.txt
|
||||
python setup.py develop
|
||||
elif [ "$TEST_TYPE" = lint ]; then
|
||||
pip install flake8
|
||||
|
|
12
requirements-dev.txt
Normal file
12
requirements-dev.txt
Normal file
|
@ -0,0 +1,12 @@
|
|||
-e .
|
||||
pytest
|
||||
pytest-benchmark
|
||||
pytest-cov
|
||||
pytest-mock
|
||||
snapshottest
|
||||
coveralls
|
||||
six
|
||||
mock
|
||||
pytz
|
||||
iso8601
|
||||
pre-commit
|
36
setup.py
36
setup.py
|
@ -3,7 +3,6 @@ import re
|
|||
import sys
|
||||
|
||||
from setuptools import find_packages, setup
|
||||
from setuptools.command.test import test as TestCommand
|
||||
|
||||
_version_re = re.compile(r'VERSION\s+=\s+(.*)')
|
||||
|
||||
|
@ -23,38 +22,6 @@ except Exception:
|
|||
sys.path[:] = path_copy
|
||||
|
||||
|
||||
class PyTest(TestCommand):
|
||||
user_options = [('pytest-args=', 'a', "Arguments to pass to 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 here, cause outside the eggs aren't loaded
|
||||
import pytest
|
||||
errno = pytest.main(self.pytest_args)
|
||||
sys.exit(errno)
|
||||
|
||||
|
||||
tests_require = [
|
||||
'pytest',
|
||||
'pytest-benchmark',
|
||||
'pytest-cov',
|
||||
'pytest-mock',
|
||||
'snapshottest',
|
||||
'coveralls',
|
||||
'six',
|
||||
'mock',
|
||||
'pytz',
|
||||
'iso8601',
|
||||
]
|
||||
|
||||
setup(
|
||||
name='graphene',
|
||||
version=version,
|
||||
|
@ -94,9 +61,7 @@ setup(
|
|||
'promise>=2.1,<3',
|
||||
'aniso8601>=3,<4',
|
||||
],
|
||||
tests_require=tests_require,
|
||||
extras_require={
|
||||
'test': tests_require,
|
||||
'django': [
|
||||
'graphene-django',
|
||||
],
|
||||
|
@ -104,5 +69,4 @@ setup(
|
|||
'graphene-sqlalchemy',
|
||||
]
|
||||
},
|
||||
cmdclass={'test': PyTest},
|
||||
)
|
||||
|
|
Loading…
Reference in New Issue
Block a user