-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add initialCount support to rust compiler
- Loading branch information
1 parent
9e9c8ab
commit a5a48a6
Showing
13 changed files
with
146 additions
and
3 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
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
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
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
31 changes: 31 additions & 0 deletions
31
...ransforms/tests/defer_stream/fixtures/fragment-with-stream-initial-count-arg-oss.expected
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,31 @@ | ||
==================================== INPUT ==================================== | ||
query QueryWithFragmentWithStream($id: ID!, $initialCount: Int) { | ||
node(id: $id) { | ||
id | ||
...FeedbackFragment | ||
} | ||
} | ||
|
||
fragment FeedbackFragment on Feedback { | ||
id | ||
actors @stream(initialCount: $initialCount, label: "StreamedActorsLabel") { | ||
name | ||
} | ||
} | ||
==================================== OUTPUT =================================== | ||
query QueryWithFragmentWithStream( | ||
$id: ID! | ||
$initialCount: Int | ||
) { | ||
node(id: $id) { | ||
id | ||
...FeedbackFragment | ||
} | ||
} | ||
|
||
fragment FeedbackFragment on Feedback { | ||
id | ||
actors @stream(label: "FeedbackFragment$stream$StreamedActorsLabel", initialCount: $initialCount) { | ||
name | ||
} | ||
} |
13 changes: 13 additions & 0 deletions
13
...transforms/tests/defer_stream/fixtures/fragment-with-stream-initial-count-arg-oss.graphql
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,13 @@ | ||
query QueryWithFragmentWithStream($id: ID!, $initialCount: Int) { | ||
node(id: $id) { | ||
id | ||
...FeedbackFragment | ||
} | ||
} | ||
|
||
fragment FeedbackFragment on Feedback { | ||
id | ||
actors @stream(initialCount: $initialCount, label: "StreamedActorsLabel") { | ||
name | ||
} | ||
} |
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
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
57 changes: 57 additions & 0 deletions
57
...es/graphql-transforms/tests/transform_connections/fixtures/stream-connection-oss.expected
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,57 @@ | ||
==================================== INPUT ==================================== | ||
query NodeQuery($id: ID!) { | ||
node(id: $id) { | ||
id | ||
... on Story { | ||
comments(first: 10) | ||
@stream_connection(key: "NodeQuery_comments", initialCount: 0) { | ||
edges { | ||
node { | ||
actor { | ||
name | ||
} | ||
} | ||
} | ||
pageInfo { | ||
endCursor | ||
hasNextPage | ||
} | ||
} | ||
} | ||
} | ||
} | ||
==================================== OUTPUT =================================== | ||
query NodeQuery( | ||
$id: ID! | ||
) @__connectionMetadata(__connectionMetadataArgument: [[["node", "comments"], "forward", null, null, null, null, true]]) { | ||
node(id: $id) { | ||
id | ||
... on Story { | ||
comments(first: 10) @__clientField(key: "NodeQuery_comments", handle: "connection") { | ||
edges @stream(label: "NodeQuery_comments", initialCount: 0) { | ||
node { | ||
actor { | ||
name | ||
} | ||
} | ||
... on CommentsEdge { | ||
cursor | ||
node { | ||
__typename | ||
} | ||
} | ||
} | ||
... @defer(label: "NodeQuery$defer$NodeQuery_comments$pageInfo") { | ||
pageInfo { | ||
endCursor | ||
hasNextPage | ||
... on PageInfo { | ||
endCursor | ||
hasNextPage | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} |
21 changes: 21 additions & 0 deletions
21
...tes/graphql-transforms/tests/transform_connections/fixtures/stream-connection-oss.graphql
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 @@ | ||
query NodeQuery($id: ID!) { | ||
node(id: $id) { | ||
id | ||
... on Story { | ||
comments(first: 10) | ||
@stream_connection(key: "NodeQuery_comments", initialCount: 0) { | ||
edges { | ||
node { | ||
actor { | ||
name | ||
} | ||
} | ||
} | ||
pageInfo { | ||
endCursor | ||
hasNextPage | ||
} | ||
} | ||
} | ||
} | ||
} |
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
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
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