Skip to content
This repository was archived by the owner on Apr 1, 2024. It is now read-only.

Commit d48d5cd

Browse files
committed
added test for specifiedBy resolver
1 parent 6c3a192 commit d48d5cd

File tree

1 file changed

+40
-0
lines changed

1 file changed

+40
-0
lines changed

internal/gqlgen/gqlgen_test.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -304,4 +304,44 @@ tests:
304304
{"isRepeatable":false,"name":"skip"},
305305
{"isRepeatable":false,"name":"specifiedBy"}
306306
]}
307+
}
308+
309+
- name: querying for specifiedBy
310+
schema: |
311+
scalar UUID @specifiedBy(url: "https://tools.ietf.org/html/rfc4122")
312+
313+
type Query {
314+
id: ID
315+
uuid: UUID
316+
}
317+
query: |
318+
{
319+
__schema {
320+
types {
321+
name
322+
specifiedBy
323+
}
324+
}
325+
}
326+
json: |
327+
{"__schema":
328+
{
329+
"types":[
330+
{"name":"Boolean","specifiedBy":null},
331+
{"name":"Float","specifiedBy":null},
332+
{"name":"ID","specifiedBy":null},
333+
{"name":"Int","specifiedBy":null},
334+
{"name":"Query","specifiedBy":null},
335+
{"name":"String","specifiedBy":null},
336+
{"name":"UUID","specifiedBy":"https://tools.ietf.org/html/rfc4122"},
337+
{"name":"__Directive","specifiedBy":null},
338+
{"name":"__DirectiveLocation","specifiedBy":null},
339+
{"name":"__EnumValue","specifiedBy":null},
340+
{"name":"__Field","specifiedBy":null},
341+
{"name":"__InputValue","specifiedBy":null},
342+
{"name":"__Schema","specifiedBy":null},
343+
{"name":"__Type","specifiedBy":null},
344+
{"name":"__TypeKind","specifiedBy":null}
345+
]
346+
}
307347
}

0 commit comments

Comments
 (0)