File tree 3 files changed +13
-3
lines changed 3 files changed +13
-3
lines changed Original file line number Diff line number Diff line change @@ -16,7 +16,7 @@ The current version 3.0.0b1 of GraphQL-core is up-to-date
16
16
with GraphQL.js version 14.5.6.
17
17
18
18
All parts of the API are covered by an extensive test suite
19
- of currently 1989 unit tests.
19
+ of currently 1990 unit tests.
20
20
21
21
22
22
## Documentation
Original file line number Diff line number Diff line change @@ -94,8 +94,7 @@ def coerce_variable_values(
94
94
coerced_values [var_name ] = value_from_ast (
95
95
var_def_node .default_value , var_type
96
96
)
97
-
98
- if is_non_null_type (var_type ):
97
+ elif is_non_null_type (var_type ):
99
98
var_type_str = inspect (var_type )
100
99
on_error (
101
100
GraphQLError (
Original file line number Diff line number Diff line change @@ -546,6 +546,17 @@ def allows_nullable_inputs_to_be_set_to_a_value_directly():
546
546
assert result == ({"fieldWithNullableStringInput" : "'a'" }, None )
547
547
548
548
def describe_handles_non_nullable_scalars ():
549
+ def allows_non_nullable_variable_to_be_omitted_given_a_default ():
550
+ result = execute_query (
551
+ """
552
+ query ($value: String! = "default") {
553
+ fieldWithNullableStringInput(input: $value)
554
+ }
555
+ """
556
+ )
557
+
558
+ assert result == ({"fieldWithNullableStringInput" : "'default'" }, None )
559
+
549
560
def allows_non_nullable_inputs_to_be_omitted_given_a_default ():
550
561
result = execute_query (
551
562
"""
You can’t perform that action at this time.
0 commit comments