mirror of
https://github.com/graphql-python/graphene.git
synced 2024-11-22 09:36:44 +03:00
Added test extra requirements
This commit is contained in:
parent
8f373ccec3
commit
256c84a9a5
|
@ -22,8 +22,7 @@ before_install:
|
||||||
install:
|
install:
|
||||||
- |
|
- |
|
||||||
if [ "$TEST_TYPE" = build ]; then
|
if [ "$TEST_TYPE" = build ]; then
|
||||||
pip install pytest pytest-cov pytest-benchmark coveralls six pytz iso8601
|
pip install -e .[test]
|
||||||
pip install -e .
|
|
||||||
python setup.py develop
|
python setup.py develop
|
||||||
elif [ "$TEST_TYPE" = lint ]; then
|
elif [ "$TEST_TYPE" = lint ]; then
|
||||||
pip install flake8
|
pip install flake8
|
||||||
|
|
10
README.md
10
README.md
|
@ -75,13 +75,19 @@ If you want to learn even more, you can also check the following [examples](exam
|
||||||
After cloning this repo, ensure dependencies are installed by running:
|
After cloning this repo, ensure dependencies are installed by running:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
python setup.py install
|
pip install .[test]
|
||||||
```
|
```
|
||||||
|
|
||||||
After developing, the full test suite can be evaluated by running:
|
After developing, the full test suite can be evaluated by running:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
python setup.py test # Use --pytest-args="-v -s" for verbose mode
|
py.test graphene --cov=graphene --benchmark-skip # Use -v -s for verbose mode
|
||||||
|
```
|
||||||
|
|
||||||
|
You can also run the benchmarks with:
|
||||||
|
|
||||||
|
```sh
|
||||||
|
py.test graphene --benchmark-only
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
|
|
10
README.rst
10
README.rst
|
@ -89,13 +89,19 @@ After cloning this repo, ensure dependencies are installed by running:
|
||||||
|
|
||||||
.. code:: sh
|
.. code:: sh
|
||||||
|
|
||||||
python setup.py install
|
pip install .[test]
|
||||||
|
|
||||||
After developing, the full test suite can be evaluated by running:
|
After developing, the full test suite can be evaluated by running:
|
||||||
|
|
||||||
.. code:: sh
|
.. code:: sh
|
||||||
|
|
||||||
python setup.py test # Use --pytest-args="-v -s" for verbose mode
|
py.test graphene --cov=graphene --benchmark-skip # Use -v -s for verbose mode
|
||||||
|
|
||||||
|
You can also run the benchmarks with:
|
||||||
|
|
||||||
|
.. code:: sh
|
||||||
|
|
||||||
|
py.test graphene --benchmark-only
|
||||||
|
|
||||||
Documentation
|
Documentation
|
||||||
~~~~~~~~~~~~~
|
~~~~~~~~~~~~~
|
||||||
|
|
20
setup.py
20
setup.py
|
@ -37,6 +37,17 @@ class PyTest(TestCommand):
|
||||||
errno = pytest.main(self.pytest_args)
|
errno = pytest.main(self.pytest_args)
|
||||||
sys.exit(errno)
|
sys.exit(errno)
|
||||||
|
|
||||||
|
tests_require = [
|
||||||
|
'pytest>=2.7.2',
|
||||||
|
'pytest-benchmark',
|
||||||
|
'pytest-cov',
|
||||||
|
'coveralls',
|
||||||
|
'six',
|
||||||
|
'mock',
|
||||||
|
'pytz',
|
||||||
|
'iso8601',
|
||||||
|
]
|
||||||
|
|
||||||
setup(
|
setup(
|
||||||
name='graphene',
|
name='graphene',
|
||||||
version=version,
|
version=version,
|
||||||
|
@ -74,14 +85,9 @@ setup(
|
||||||
'graphql-relay>=0.4.5',
|
'graphql-relay>=0.4.5',
|
||||||
'promise>=1.0.1',
|
'promise>=1.0.1',
|
||||||
],
|
],
|
||||||
tests_require=[
|
tests_require=tests_require,
|
||||||
'pytest>=2.7.2',
|
|
||||||
'pytest-benchmark',
|
|
||||||
'mock',
|
|
||||||
'pytz',
|
|
||||||
'iso8601',
|
|
||||||
],
|
|
||||||
extras_require={
|
extras_require={
|
||||||
|
'test': tests_require,
|
||||||
'django': [
|
'django': [
|
||||||
'graphene-django',
|
'graphene-django',
|
||||||
],
|
],
|
||||||
|
|
Loading…
Reference in New Issue
Block a user