From 1c7c3b8b2f3d234a8110a7ad5a4938c22aa1a255 Mon Sep 17 00:00:00 2001 From: Noelle Leigh Date: Fri, 17 Apr 2020 15:50:56 -0400 Subject: [PATCH] Replace "operation_name" with "operationName" --- graphene_django/utils/testing.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/graphene_django/utils/testing.py b/graphene_django/utils/testing.py index 8a9b994..0f68a51 100644 --- a/graphene_django/utils/testing.py +++ b/graphene_django/utils/testing.py @@ -32,20 +32,20 @@ class GraphQLTestCase(TestCase): supply the op_name. For annon queries ("{ ... }"), should be None (default). input_data (dict) - If provided, the $input variable in GraphQL will be set - to this value. If both ``input_data`` and ``variables``, + to this value. If both ``input_data`` and ``variables``, are provided, the ``input`` field in the ``variables`` dict will be overwritten with this value. variables (dict) - If provided, the "variables" field in GraphQL will be set to this value. headers (dict) - If provided, the headers in POST request to GRAPHQL_URL - will be set to this value. + will be set to this value. Returns: Response object from client """ body = {"query": query} if op_name: - body["operation_name"] = op_name + body["operationName"] = op_name if variables: body["variables"] = variables if input_data: