Skip to content

Commit b3c99aa

Browse files
committed
Update schema printer tests
1 parent 4b4935f commit b3c99aa

File tree

5 files changed

+17
-17
lines changed

5 files changed

+17
-17
lines changed

src/test/groovy/graphql/Issue2141.groovy

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ class Issue2141 extends Specification {
2727
"Marks the field, argument, input field or enum value as deprecated"
2828
directive @deprecated(
2929
"The reason for the deprecation"
30-
reason: String = "No longer supported"
30+
reason: String! = "No longer supported"
3131
) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
3232
3333
"Directs the executor to include this field or fragment only when the `if` argument is true"

src/test/groovy/graphql/schema/idl/SchemaPrinterTest.groovy

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -968,7 +968,7 @@ type Query {
968968
"Marks the field, argument, input field or enum value as deprecated"
969969
directive @deprecated(
970970
"The reason for the deprecation"
971-
reason: String = "No longer supported"
971+
reason: String! = "No longer supported"
972972
) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
973973
974974
directive @enumTypeDirective on ENUM
@@ -1144,7 +1144,7 @@ input SomeInput {
11441144
result == '''"Marks the field, argument, input field or enum value as deprecated"
11451145
directive @deprecated(
11461146
"The reason for the deprecation"
1147-
reason: String = "No longer supported"
1147+
reason: String! = "No longer supported"
11481148
) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
11491149
11501150
"Directs the executor to include this field or fragment only when the `if` argument is true"
@@ -1240,7 +1240,7 @@ type Query {
12401240
resultWithDirectives == '''"Marks the field, argument, input field or enum value as deprecated"
12411241
directive @deprecated(
12421242
"The reason for the deprecation"
1243-
reason: String = "No longer supported"
1243+
reason: String! = "No longer supported"
12441244
) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
12451245
12461246
directive @example on FIELD_DEFINITION
@@ -1308,7 +1308,7 @@ type Query {
13081308
resultWithDirectiveDefinitions == '''"Marks the field, argument, input field or enum value as deprecated"
13091309
directive @deprecated(
13101310
"The reason for the deprecation"
1311-
reason: String = "No longer supported"
1311+
reason: String! = "No longer supported"
13121312
) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
13131313
13141314
directive @example on FIELD_DEFINITION
@@ -1405,7 +1405,7 @@ extend schema {
14051405
"Marks the field, argument, input field or enum value as deprecated"
14061406
directive @deprecated(
14071407
"The reason for the deprecation"
1408-
reason: String = "No longer supported"
1408+
reason: String! = "No longer supported"
14091409
) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
14101410
14111411
"Directs the executor to include this field or fragment only when the `if` argument is true"
@@ -1491,7 +1491,7 @@ schema @schemaDirective{
14911491
"Marks the field, argument, input field or enum value as deprecated"
14921492
directive @deprecated(
14931493
"The reason for the deprecation"
1494-
reason: String = "No longer supported"
1494+
reason: String! = "No longer supported"
14951495
) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
14961496
14971497
"Directs the executor to include this field or fragment only when the `if` argument is true"
@@ -1631,7 +1631,7 @@ type MyQuery {
16311631
result == '''"Marks the field, argument, input field or enum value as deprecated"
16321632
directive @deprecated(
16331633
"The reason for the deprecation"
1634-
reason: String = "No longer supported"
1634+
reason: String! = "No longer supported"
16351635
) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
16361636
16371637
directive @directive1 on SCALAR
@@ -1873,7 +1873,7 @@ type Query {
18731873
result == '''"Marks the field, argument, input field or enum value as deprecated"
18741874
directive @deprecated(
18751875
"The reason for the deprecation"
1876-
reason: String = "No longer supported"
1876+
reason: String! = "No longer supported"
18771877
) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
18781878
18791879
type Query {
@@ -2167,7 +2167,7 @@ type PrintMeType {
21672167
"Marks the field, argument, input field or enum value as deprecated"
21682168
directive @deprecated(
21692169
"The reason for the deprecation"
2170-
reason: String = "No longer supported"
2170+
reason: String! = "No longer supported"
21712171
) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
21722172
21732173
directive @foo on SCHEMA
@@ -2399,7 +2399,7 @@ directive @include(
23992399
"Marks the field, argument, input field or enum value as deprecated"
24002400
directive @deprecated(
24012401
"The reason for the deprecation"
2402-
reason: String = "No longer supported"
2402+
reason: String! = "No longer supported"
24032403
) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
24042404
24052405
union ZUnion = XQuery | Query
@@ -2515,7 +2515,7 @@ schema {
25152515
"Marks the field, argument, input field or enum value as deprecated"
25162516
directive @deprecated(
25172517
"The reason for the deprecation"
2518-
reason: String = "No longer supported"
2518+
reason: String! = "No longer supported"
25192519
) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
25202520
25212521
" custom directive 'example' description 1"
@@ -2752,7 +2752,7 @@ schema {
27522752
"Marks the field, argument, input field or enum value as deprecated"
27532753
directive @deprecated(
27542754
"The reason for the deprecation"
2755-
reason: String = "No longer supported"
2755+
reason: String! = "No longer supported"
27562756
) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
27572757
27582758
" custom directive 'example' description 1"
@@ -2940,7 +2940,7 @@ input Input {
29402940
result == """"Marks the field, argument, input field or enum value as deprecated"
29412941
directive @deprecated(
29422942
"The reason for the deprecation"
2943-
reason: String = "No longer supported"
2943+
reason: String! = "No longer supported"
29442944
) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
29452945
29462946
"Directs the executor to include this field or fragment only when the `if` argument is true"

src/test/groovy/graphql/util/AnonymizerTest.groovy

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -729,7 +729,7 @@ type Object1 {
729729
730730
directive @Directive1(argument1: String! = "stringValue4") repeatable on SCHEMA | SCALAR | OBJECT | FIELD_DEFINITION | ARGUMENT_DEFINITION | INTERFACE | UNION | ENUM | ENUM_VALUE | INPUT_OBJECT | INPUT_FIELD_DEFINITION
731731
732-
directive @deprecated(reason: String) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
732+
directive @deprecated(reason: String!) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
733733
734734
interface Interface1 @Directive1(argument1 : "stringValue12") {
735735
field2: String

src/test/resources/large-schema-1.graphqls

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ directive @skip(
1515
if: Boolean!
1616
) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT
1717

18-
directive @deprecated(reason: String) on FIELD_DEFINITION | ENUM_VALUE
18+
directive @deprecated(reason: String!) on FIELD_DEFINITION | ENUM_VALUE
1919

2020
"Exposes a URL that specifies the behaviour of this scalar."
2121
directive @specifiedBy(

src/test/resources/many-fragments.graphqls

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ directive @Directive8(argument7: Enum3!) on FIELD_DEFINITION
2525

2626
directive @Directive9(argument8: String!) on OBJECT
2727

28-
directive @deprecated(reason: String) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
28+
directive @deprecated(reason: String!) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
2929

3030
"Directs the executor to include this field or fragment only when the `if` argument is true"
3131
directive @include(

0 commit comments

Comments
 (0)