mirror of
https://github.com/graphql-python/graphene.git
synced 2025-02-02 12:44:15 +03:00
Moved all the examples from tests to examples
This commit is contained in:
parent
f4c1e711cc
commit
3bc0f5f8eb
2
.gitignore
vendored
2
.gitignore
vendored
|
@ -59,3 +59,5 @@ docs/_build/
|
||||||
# PyBuilder
|
# PyBuilder
|
||||||
target/
|
target/
|
||||||
|
|
||||||
|
|
||||||
|
/tests/django.sqlite
|
||||||
|
|
|
@ -49,8 +49,8 @@ result = schema.execute(query)
|
||||||
|
|
||||||
If you want to learn even more, you can also check the following examples:
|
If you want to learn even more, you can also check the following examples:
|
||||||
|
|
||||||
* Relay Schema: [Starwars Relay example](tests/starwars_relay)
|
* Relay Schema: [Starwars Relay example](examples/starwars_relay)
|
||||||
* Django: [Starwars Django example](tests/starwars_django)
|
* Django: [Starwars Django example](examples/starwars_django)
|
||||||
|
|
||||||
|
|
||||||
## Contributing
|
## Contributing
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
from .schema import Schema, Query
|
from ..schema import Schema, Query
|
||||||
from graphql.core import graphql
|
from graphql.core import graphql
|
||||||
from .data import setup
|
from ..data import setup
|
||||||
|
|
||||||
setup()
|
setup()
|
||||||
|
|
0
examples/starwars_django/__init__.py
Normal file
0
examples/starwars_django/__init__.py
Normal file
0
examples/starwars_django/tests/__init__.py
Normal file
0
examples/starwars_django/tests/__init__.py
Normal file
|
@ -1,9 +1,9 @@
|
||||||
import pytest
|
import pytest
|
||||||
from graphql.core import graphql
|
from graphql.core import graphql
|
||||||
|
|
||||||
from .models import *
|
from ..models import *
|
||||||
from .schema import schema
|
from ..schema import schema
|
||||||
from .data import initialize
|
from ..data import initialize
|
||||||
|
|
||||||
pytestmark = pytest.mark.django_db
|
pytestmark = pytest.mark.django_db
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
import pytest
|
import pytest
|
||||||
from pytest import raises
|
from pytest import raises
|
||||||
from graphql.core import graphql
|
from graphql.core import graphql
|
||||||
from .data import initialize
|
from ..data import initialize
|
||||||
|
|
||||||
from .schema import schema
|
from ..schema import schema
|
||||||
|
|
||||||
pytestmark = pytest.mark.django_db
|
pytestmark = pytest.mark.django_db
|
||||||
|
|
0
examples/starwars_relay/__init__.py
Normal file
0
examples/starwars_relay/__init__.py
Normal file
0
examples/starwars_relay/tests/__init__.py
Normal file
0
examples/starwars_relay/tests/__init__.py
Normal file
|
@ -1,5 +1,5 @@
|
||||||
from .schema import schema
|
from ..schema import schema
|
||||||
from .data import setup
|
from ..data import setup
|
||||||
|
|
||||||
setup()
|
setup()
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
from .schema import schema
|
from ..schema import schema
|
||||||
from .data import setup
|
from ..data import setup
|
||||||
|
|
||||||
setup()
|
setup()
|
||||||
|
|
|
@ -2,7 +2,7 @@ SECRET_KEY = 1
|
||||||
|
|
||||||
INSTALLED_APPS = [
|
INSTALLED_APPS = [
|
||||||
'graphene.contrib.django',
|
'graphene.contrib.django',
|
||||||
'tests.starwars_django',
|
'examples.starwars_django',
|
||||||
'tests.contrib_django',
|
'tests.contrib_django',
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user