Skip to content

Commit d11320e

Browse files
committed
update kitchen sink schema
1 parent ec3721a commit d11320e

File tree

1 file changed

+100
-13
lines changed

1 file changed

+100
-13
lines changed

Tests/GraphQLTests/LanguageTests/schema-kitchen-sink.graphql

Lines changed: 100 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -10,66 +10,153 @@ schema {
1010
mutation: MutationType
1111
}
1212

13-
type Foo implements Bar {
13+
"""
14+
This is a description
15+
of the `Foo` type.
16+
"""
17+
type Foo implements Bar & Baz & Two {
18+
"Description of the `one` field."
1419
one: Type
15-
two(argument: InputType!): Type
20+
"""
21+
This is a description of the `two` field.
22+
"""
23+
two(
24+
"""
25+
This is a description of the `argument` argument.
26+
"""
27+
argument: InputType!
28+
): Type
29+
"""This is a description of the `three` field."""
1630
three(argument: InputType, other: String): Int
1731
four(argument: String = "string"): String
1832
five(argument: [String] = ["string", "string"]): String
1933
six(argument: InputType = {key: "value"}): Type
34+
seven(argument: Int = null): Type
2035
}
2136

2237
type AnnotatedObject @onObject(arg: "value") {
23-
annotatedField(arg: Type = "default" @onArg): Type @onField
38+
annotatedField(arg: Type = "default" @onArgumentDefinition): Type @onField
39+
}
40+
41+
type UndefinedType
42+
43+
extend type Foo {
44+
seven(argument: [String]): Type
2445
}
2546

47+
extend type Foo @onType
48+
2649
interface Bar {
2750
one: Type
2851
four(argument: String = "string"): String
2952
}
3053

3154
interface AnnotatedInterface @onInterface {
32-
annotatedField(arg: Type @onArg): Type @onField
55+
annotatedField(arg: Type @onArgumentDefinition): Type @onField
3356
}
3457

35-
union Feed = Story | Article | Advert
58+
interface UndefinedInterface
59+
60+
extend interface Bar implements Two {
61+
two(argument: InputType!): Type
62+
}
63+
64+
extend interface Bar @onInterface
65+
66+
interface Baz implements Bar & Two {
67+
one: Type
68+
two(argument: InputType!): Type
69+
four(argument: String = "string"): String
70+
}
71+
72+
union Feed =
73+
| Story
74+
| Article
75+
| Advert
3676

3777
union AnnotatedUnion @onUnion = A | B
3878

79+
union AnnotatedUnionTwo @onUnion = | A | B
80+
81+
union UndefinedUnion
82+
83+
extend union Feed = Photo | Video
84+
85+
extend union Feed @onUnion
86+
3987
scalar CustomScalar
4088

4189
scalar AnnotatedScalar @onScalar
4290

91+
extend scalar CustomScalar @onScalar
92+
4393
enum Site {
94+
"""
95+
This is a description of the `DESKTOP` value
96+
"""
4497
DESKTOP
98+
99+
"""This is a description of the `MOBILE` value"""
45100
MOBILE
101+
102+
"This is a description of the `WEB` value"
103+
WEB
46104
}
47105

48106
enum AnnotatedEnum @onEnum {
49107
ANNOTATED_VALUE @onEnumValue
50108
OTHER_VALUE
51109
}
52110

111+
enum UndefinedEnum
112+
113+
extend enum Site {
114+
VR
115+
}
116+
117+
extend enum Site @onEnum
118+
53119
input InputType {
54120
key: String!
55121
answer: Int = 42
56122
}
57123

58-
input AnnotatedInput @onInputObjectType {
59-
annotatedField: Type @onField
124+
input AnnotatedInput @onInputObject {
125+
annotatedField: Type @onInputFieldDefinition
60126
}
61127

62-
extend type Foo {
63-
seven(argument: [String]): Type
64-
}
128+
input UndefinedInput
65129

66-
extend type Foo @onType {}
130+
extend input InputType {
131+
other: Float = 1.23e4 @onInputFieldDefinition
132+
}
67133

68-
type NoFields {}
134+
extend input InputType @onInputObject
69135

70-
directive @skip(if: Boolean!) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT
136+
"""
137+
This is a description of the `@skip` directive
138+
"""
139+
directive @skip(
140+
"""This is a description of the `if` argument"""
141+
if: Boolean! @onArgumentDefinition
142+
) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT
71143

72144
directive @include(if: Boolean!)
73145
on FIELD
74146
| FRAGMENT_SPREAD
75147
| INLINE_FRAGMENT
148+
149+
directive @include2(if: Boolean!) on
150+
| FIELD
151+
| FRAGMENT_SPREAD
152+
| INLINE_FRAGMENT
153+
154+
directive @myRepeatableDir(name: String!) repeatable on
155+
| OBJECT
156+
| INTERFACE
157+
158+
extend schema @onSchema
159+
160+
extend schema @onSchema {
161+
subscription: SubscriptionType
162+
}

0 commit comments

Comments
 (0)