Skip to content

Commit f49f54e

Browse files
committed
test: Make both python2 and python3 pass
1 parent b13bbdf commit f49f54e

File tree

2 files changed

+4
-8
lines changed

2 files changed

+4
-8
lines changed

graphene_mongo/tests/test_relay_query.py

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
import json
21
import pytest
32

43
import graphene
@@ -271,8 +270,7 @@ class Query(graphene.ObjectType):
271270
schema = graphene.Schema(query=Query)
272271
result = schema.execute(query)
273272
assert not result.errors
274-
assert json.dumps(result.data, sort_keys=True) == json.dumps(
275-
expected, sort_keys=True)
273+
assert result.data == expected
276274

277275

278276
def test_should_filter_by_reference_field(fixtures):
@@ -312,8 +310,7 @@ class Query(graphene.ObjectType):
312310
schema = graphene.Schema(query=Query)
313311
result = schema.execute(query)
314312
assert not result.errors
315-
assert json.dumps(result.data, sort_keys=True) == json.dumps(
316-
expected, sort_keys=True)
313+
assert result.data == expected
317314

318315

319316
def test_should_filter_through_inheritance(fixtures):
@@ -357,8 +354,7 @@ class Query(graphene.ObjectType):
357354
schema = graphene.Schema(query=Query)
358355
result = schema.execute(query)
359356
assert not result.errors
360-
assert json.dumps(result.data, sort_keys=True) == json.dumps(
361-
expected, sort_keys=True)
357+
assert result.data == expected
362358

363359

364360
def test_should_filter_by_list_contains(fixtures):

graphene_mongo/tests/types.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import models
1+
from . import models
22
from ..types import MongoengineObjectType
33

44

0 commit comments

Comments
 (0)