Skip to content

Commit 5f2784e

Browse files
committed
Adjust the GitHub GQL schema to use spec-compliant descriptions
It looks like the string literal style for descriptions in the schema language is becoming the standard. Sources: - graphql/graphql-spec#466 - https://stackoverflow.com/questions/39962867/how-do-i-add-a-description-to-a-field-in-graphql-schema-language - https://medium.com/apollo-stack/all-you-need-to-know-about-graphql-js-0-7-921e75dd7fd1#.t9csdknur
1 parent 845618a commit 5f2784e

File tree

2 files changed

+2996
-2929
lines changed

2 files changed

+2996
-2929
lines changed

graphql_query_derive/src/tests/github.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,17 @@ fn ast_from_graphql_and_json_produce_the_same_schema() {
1414
let graphql_parser_schema = graphql_parser::parse_schema(SCHEMA_GRAPHQL).unwrap();
1515
let json = Schema::from(json);
1616
let gql = Schema::from(graphql_parser_schema);
17+
1718
assert_eq!(json.scalars, gql.scalars);
1819
for (json, gql) in json.objects.iter().zip(gql.objects.iter()) {
1920
assert_eq!(json, gql)
2021
}
2122
for (json, gql) in json.unions.iter().zip(gql.unions.iter()) {
2223
assert_eq!(json, gql)
2324
}
25+
for (json, gql) in json.interfaces.iter().zip(gql.interfaces.iter()) {
26+
assert_eq!(json, gql)
27+
}
2428
assert_eq!(json.interfaces, gql.interfaces);
2529
assert_eq!(json.query_type, gql.query_type);
2630
assert_eq!(json.mutation_type, gql.mutation_type);

0 commit comments

Comments
 (0)