-
Notifications
You must be signed in to change notification settings - Fork 259
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: recursive types on
@graphql
directive (#2528)
- Loading branch information
Showing
4 changed files
with
115 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
55 changes: 55 additions & 0 deletions
55
tests/core/snapshots/related-fields-recursive.md_client.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
--- | ||
source: tests/core/spec.rs | ||
expression: formatted | ||
--- | ||
scalar Bytes | ||
|
||
scalar Date | ||
|
||
scalar Email | ||
|
||
scalar Empty | ||
|
||
scalar Int128 | ||
|
||
scalar Int16 | ||
|
||
scalar Int32 | ||
|
||
scalar Int64 | ||
|
||
scalar Int8 | ||
|
||
scalar JSON | ||
|
||
type NodeA { | ||
name: String | ||
nodeB: NodeB | ||
} | ||
|
||
type NodeB { | ||
name: String | ||
nodeA: NodeA | ||
} | ||
|
||
scalar PhoneNumber | ||
|
||
type Query { | ||
queryNodeA: [NodeA] | ||
} | ||
|
||
scalar UInt128 | ||
|
||
scalar UInt16 | ||
|
||
scalar UInt32 | ||
|
||
scalar UInt64 | ||
|
||
scalar UInt8 | ||
|
||
scalar Url | ||
|
||
schema { | ||
query: Query | ||
} |
23 changes: 23 additions & 0 deletions
23
tests/core/snapshots/related-fields-recursive.md_merged.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
--- | ||
source: tests/core/spec.rs | ||
expression: formatter | ||
--- | ||
schema @server(hostname: "0.0.0.0", port: 8000) @upstream(baseURL: "http://localhost:8083/graphql") { | ||
query: Query | ||
} | ||
|
||
scalar DateTime | ||
|
||
type NodeA { | ||
name: String | ||
nodeB: NodeB | ||
} | ||
|
||
type NodeB { | ||
name: String | ||
nodeA: NodeA | ||
} | ||
|
||
type Query { | ||
queryNodeA: [NodeA] @graphQL(name: "queryNodeA") | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
```graphql @config | ||
scalar DateTime | ||
|
||
schema @server(port: 8000, hostname: "0.0.0.0") @upstream(baseURL: "http://localhost:8083/graphql") { | ||
query: Query | ||
} | ||
|
||
type Query { | ||
queryNodeA: [NodeA] @graphQL(name: "queryNodeA", batch: false) | ||
} | ||
|
||
type NodeA { | ||
name: String | ||
nodeB: NodeB | ||
} | ||
|
||
type NodeB { | ||
name: String | ||
nodeA: NodeA | ||
} | ||
``` |