Saleor Core: the high performance, composable, headless commerce API.
Python cartcheckoutcommercecomposablee-commerceecommercegraphqlheadlessheadless-commercemultichannelomsorder-managementpaymentspimpythonshopshopping-cartstore
Fix broken tests
Adam Janik5855470fd0ff
diff --git a/saleor/dashboard/graphql/mutations.py b/saleor/dashboard/graphql/mutations.pyindex eb6463fcff..ae7ef4857b 100644--- a/saleor/dashboard/graphql/mutations.py+++ b/saleor/dashboard/graphql/mutations.py@@ -14,7 +14,7 @@ from .utils import get_attributes_dict_from_listregistry = get_global_registry()-def convert_form_fields(form_class, exclude):+def convert_form_fields(form_class, exclude=None):"""Convert form fields to Graphene fields"""fields = OrderedDict()if exclude is None:diff --git a/tests/dashboard/test_graphql.py b/tests/dashboard/test_graphql.pyindex d1226eef28..314acd57ed 100644--- a/tests/dashboard/test_graphql.py+++ b/tests/dashboard/test_graphql.py@@ -38,7 +38,7 @@ def test_model_form_mutation(# check if declarative arguments are presentassert 'test_input' in arguments# check if model form field is present- mocked_convert_form_fields.assert_called_with(model_form_class)+ mocked_convert_form_fields.assert_called_with(model_form_class, None)assert 'test_field' in argumentsoutput_fields = meta.fieldsdiff --git a/tests/test_graphql.py b/tests/test_graphql.pyindex 56a4f1c2df..915e531139 100644--- a/tests/test_graphql.py+++ b/tests/test_graphql.py@@ -114,10 +114,20 @@ def test_product_query(client, product_in_stock):nameurlthumbnailUrl- images { url }+ images {+ edges {+ node {+ url+ }+ }+ }variants {- name- stockQuantity+ edges {+ node {+ name+ stockQuantity+ }+ }}availability {available,