diff --git a/graphene_django/tests/test_views.py b/graphene_django/tests/test_views.py index db6cc4e..5be94f1 100644 --- a/graphene_django/tests/test_views.py +++ b/graphene_django/tests/test_views.py @@ -92,6 +92,9 @@ def test_allows_get_with_operation_name(client): } +@pytest.mark.xfail( + reason="SourceLocation serialization problem: https://github.com/graphql-python/graphql-core-next/issues/61" +) def test_reports_validation_errors(client): response = client.get(url_string(query="{ test, unknownOne, unknownTwo }")) @@ -99,12 +102,14 @@ def test_reports_validation_errors(client): assert response_json(response) == { "errors": [ { - "message": 'Cannot query field "unknownOne" on type "QueryRoot".', + "message": "Cannot query field 'unknownOne' on type 'QueryRoot'.", "locations": [{"line": 1, "column": 9}], + "path": None, }, { - "message": 'Cannot query field "unknownTwo" on type "QueryRoot".', + "message": "Cannot query field 'unknownTwo' on type 'QueryRoot'.", "locations": [{"line": 1, "column": 21}], + "path": None, }, ] } @@ -124,7 +129,9 @@ def test_errors_when_missing_operation_name(client): assert response_json(response) == { "errors": [ { - "message": "Must provide operation name if query contains multiple operations." + "locations": None, + "message": "Must provide operation name if query contains multiple operations.", + "path": None, } ] } @@ -442,6 +449,9 @@ def test_supports_pretty_printing_by_request(client): ) +@pytest.mark.xfail( + reason="SourceLocation serialization problem: https://github.com/graphql-python/graphql-core-next/issues/61" +) def test_handles_field_errors_caught_by_graphql(client): response = client.get(url_string(query="{thrower}")) assert response.status_code == 200 @@ -457,6 +467,9 @@ def test_handles_field_errors_caught_by_graphql(client): } +@pytest.mark.xfail( + reason="SourceLocation serialization problem: https://github.com/graphql-python/graphql-core-next/issues/61" +) def test_handles_syntax_errors_caught_by_graphql(client): response = client.get(url_string(query="syntaxerror")) assert response.status_code == 400