Fixed lint & imports

This commit is contained in:
Syrus Akbary 2018-08-31 20:01:03 +02:00
parent 3e5319cf70
commit 3d41a500c9
5 changed files with 4 additions and 16 deletions

View File

@ -9,8 +9,6 @@ matrix:
python: 3.5 python: 3.5
- env: TOXENV=py36 - env: TOXENV=py36
python: 3.6 python: 3.6
- env: TOXENV=py37
python: 3.7
- env: TOXENV=pypy - env: TOXENV=pypy
python: pypy-5.7.1 python: pypy-5.7.1
- env: TOXENV=pre-commit - env: TOXENV=pre-commit

View File

@ -18,7 +18,7 @@ try:
from .thenables_asyncio import await_and_execute from .thenables_asyncio import await_and_execute
except ImportError: except ImportError:
def isawaitable(obj): def isawaitable(obj): # type: ignore
return False return False

View File

@ -3,4 +3,3 @@ def await_and_execute(obj, on_resolve):
return on_resolve(await obj) return on_resolve(await obj)
return build_resolve_async() return build_resolve_async()

View File

@ -1,16 +1,7 @@
import pytest import pytest
from graphql.execution.executors.asyncio import AsyncioExecutor from graphql.execution.executors.asyncio import AsyncioExecutor
from graphene.types import ( from graphene.types import ID, Field, ObjectType, Schema
ID,
Argument,
Field,
InputField,
InputObjectType,
NonNull,
ObjectType,
Schema,
)
from graphene.types.scalars import String from graphene.types.scalars import String
from graphene.relay.mutation import ClientIDMutation from graphene.relay.mutation import ClientIDMutation

View File

@ -3,11 +3,11 @@ envlist = flake8,py27,py34,py35,py36,py37,pre-commit,pypy,mypy
skipsdist = true skipsdist = true
[testenv] [testenv]
deps = deps =
.[test] .[test]
py{35,36,37}: pytest-asyncio py{35,36,37}: pytest-asyncio
setenv = setenv =
PYTHONPATH = .:{envdir} PYTHONPATH = .:{envdir}
commands = commands =
py{27,34,py}: py.test --cov=graphene graphene examples {posargs} py{27,34,py}: py.test --cov=graphene graphene examples {posargs}
py{35,36,37}: py.test --cov=graphene graphene examples tests_asyncio {posargs} py{35,36,37}: py.test --cov=graphene graphene examples tests_asyncio {posargs}