Skip to content

Commit 096b772

Browse files
Undo changes to resolver and updatable types
1 parent c4df407 commit 096b772

File tree

265 files changed

+663
-665
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

265 files changed

+663
-665
lines changed

compiler/crates/relay-compiler/tests/relay_compiler_integration/fixtures/client_mutation_resolver.expected

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ type Query {
3030
==================================== OUTPUT ===================================
3131
//- __generated__/barMutation.graphql.js
3232
/**
33-
* <auto-generated> SignedSource<<c9045b1c950e83cede402f0b4626a7c8>>
33+
* <auto-generated> SignedSource<<7f1de50339842bab9cecc72c6fbc076f>>
3434
* @flow
3535
* @lightSyntaxTransform
3636
* @nogrep
@@ -45,7 +45,7 @@ import type { ClientRequest, Mutation } from 'relay-runtime';
4545
import {foo_mutation as mutationFooMutationResolverType} from "../foo.js";
4646
// Type assertion validating that `mutationFooMutationResolverType` resolver is correctly implemented.
4747
// A type error here indicates that the type signature of the resolver module is incorrect.
48-
(mutationFooMutationResolverType: () => boolean | null);
48+
(mutationFooMutationResolverType: () => ?boolean);
4949
export type barMutation$variables = {||};
5050
export type barMutation$data = {|
5151
+foo_mutation: ?boolean,

compiler/crates/relay-compiler/tests/relay_compiler_integration/fixtures/client_mutation_resolver_different_mutation_ok.expected

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ export default node;
104104

105105
//- __generated__/barMutation.graphql.js
106106
/**
107-
* <auto-generated> SignedSource<<31cc6cb3ca0668ffe6884f2da3893466>>
107+
* <auto-generated> SignedSource<<6f79ca8d7718498c480388c5b22a5130>>
108108
* @flow
109109
* @lightSyntaxTransform
110110
* @nogrep
@@ -119,7 +119,7 @@ import type { ClientRequest, Mutation } from 'relay-runtime';
119119
import {baz_mutation as notCalledMutationBazMutationResolverType} from "../foo.js";
120120
// Type assertion validating that `notCalledMutationBazMutationResolverType` resolver is correctly implemented.
121121
// A type error here indicates that the type signature of the resolver module is incorrect.
122-
(notCalledMutationBazMutationResolverType: () => boolean | null);
122+
(notCalledMutationBazMutationResolverType: () => ?boolean);
123123
export type barMutation$variables = {||};
124124
export type barMutation$data = {|
125125
+baz_mutation: ?boolean,

compiler/crates/relay-compiler/tests/relay_compiler_integration/fixtures/client_schema_extension_interface_uses_resolver_type.expected

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ export default ((node/*: any*/)/*: Fragment<
176176

177177
//- __generated__/PersonComponentQuery.graphql.js
178178
/**
179-
* <auto-generated> SignedSource<<f9584e3f61d57da807edbde8546b4278>>
179+
* <auto-generated> SignedSource<<6c11d65c79f10f8cbe664d4735a1fb15>>
180180
* @flow
181181
* @lightSyntaxTransform
182182
* @nogrep
@@ -195,15 +195,15 @@ import {admin as adminAdminResolverType} from "Admin";
195195
// A type error here indicates that the type signature of the resolver module is incorrect.
196196
(adminAdminResolverType: (
197197
__relay_model_instance: Admin____relay_model_instance$data['__relay_model_instance'],
198-
) => {|
198+
) => ?{|
199199
+id: DataID,
200-
|} | null);
200+
|});
201201
import {boss as queryBossResolverType} from "Admin";
202202
// Type assertion validating that `queryBossResolverType` resolver is correctly implemented.
203203
// A type error here indicates that the type signature of the resolver module is incorrect.
204-
(queryBossResolverType: () => {|
204+
(queryBossResolverType: () => ?{|
205205
+id: DataID,
206-
|} | null);
206+
|});
207207
export type PersonComponentQuery$variables = {||};
208208
export type PersonComponentQuery$data = {|
209209
+boss: ?{|

compiler/crates/relay-compiler/tests/relay_compiler_integration/fixtures/exec_resolvers_directive_with_root_fragment.expected

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ export default node;
116116

117117
//- __generated__/UserFooFragment.graphql.js
118118
/**
119-
* <auto-generated> SignedSource<<c6276bdf3c443a503812bf90a2089b08>>
119+
* <auto-generated> SignedSource<<843aee583dbf963998562b8559b43846>>
120120
* @flow
121121
* @lightSyntaxTransform
122122
* @nogrep
@@ -132,7 +132,7 @@ import type { FragmentType } from "relay-runtime";
132132
import {bar as userBarResolverType} from "User_bar";
133133
// Type assertion validating that `userBarResolverType` resolver is correctly implemented.
134134
// A type error here indicates that the type signature of the resolver module is incorrect.
135-
(userBarResolverType: () => mixed | null);
135+
(userBarResolverType: () => ?mixed);
136136
declare export opaque type UserFooFragment$fragmentType: FragmentType;
137137
export type UserFooFragment$data = {|
138138
+bar: ?ReturnType<typeof userBarResolverType>,

compiler/crates/relay-compiler/tests/relay_compiler_integration/fixtures/multiple_resolvers_on_interface_of_all_strong_model_type.expected

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ export default ((node/*: any*/)/*: Fragment<
183183

184184
//- __generated__/PersonComponentQuery.graphql.js
185185
/**
186-
* <auto-generated> SignedSource<<63481a634199f0ea7757f9e303b9a3c8>>
186+
* <auto-generated> SignedSource<<e0022cdfb92fda66bd256d91ed716cdc>>
187187
* @flow
188188
* @lightSyntaxTransform
189189
* @nogrep
@@ -202,13 +202,13 @@ import {description as iActorDescriptionResolverType} from "IActorResolvers";
202202
// A type error here indicates that the type signature of the resolver module is incorrect.
203203
(iActorDescriptionResolverType: (
204204
model: Admin____relay_model_instance$data['__relay_model_instance'] | User____relay_model_instance$data['__relay_model_instance'],
205-
) => string | null);
205+
) => ?string);
206206
import {name as iPersonNameResolverType} from "IPersonResolvers";
207207
// Type assertion validating that `iPersonNameResolverType` resolver is correctly implemented.
208208
// A type error here indicates that the type signature of the resolver module is incorrect.
209209
(iPersonNameResolverType: (
210210
model: Admin____relay_model_instance$data['__relay_model_instance'] | User____relay_model_instance$data['__relay_model_instance'],
211-
) => string | null);
211+
) => ?string);
212212
export type PersonComponentQuery$variables = {||};
213213
export type PersonComponentQuery$data = {|
214214
+actor: ?{|

compiler/crates/relay-compiler/tests/relay_compiler_integration/fixtures/relay_resolvers_in_throw_on_field_error.expected

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,7 @@ export default ((node/*: any*/)/*: Fragment<
164164

165165
//- __generated__/fooQuery.graphql.js
166166
/**
167-
* <auto-generated> SignedSource<<31bc07f2b00ed403e2ce86668617d4b8>>
167+
* <auto-generated> SignedSource<<993d76639831b1e563cb29101f10f1c9>>
168168
* @flow
169169
* @lightSyntaxTransform
170170
* @nogrep
@@ -180,9 +180,9 @@ import type { DataID } from "relay-runtime";
180180
import {clientUser as queryClientUserResolverType} from "foo";
181181
// Type assertion validating that `queryClientUserResolverType` resolver is correctly implemented.
182182
// A type error here indicates that the type signature of the resolver module is incorrect.
183-
(queryClientUserResolverType: () => {|
183+
(queryClientUserResolverType: () => ?{|
184184
+id: DataID,
185-
|} | null);
185+
|});
186186
export type fooQuery$variables = {||};
187187
export type fooQuery$data = {|
188188
+clientUser: {|

compiler/crates/relay-compiler/tests/relay_compiler_integration/fixtures/resolver_on_interface_of_all_strong_model_type.expected

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ export default ((node/*: any*/)/*: Fragment<
168168

169169
//- __generated__/PersonComponentFragment.graphql.js
170170
/**
171-
* <auto-generated> SignedSource<<6ae25904008fca5dd338ee1e53ed18d2>>
171+
* <auto-generated> SignedSource<<fa447cade5f346d21f24221645ca4842>>
172172
* @flow
173173
* @lightSyntaxTransform
174174
* @nogrep
@@ -188,7 +188,7 @@ import {name as iPersonNameResolverType} from "IPersonResolvers";
188188
// A type error here indicates that the type signature of the resolver module is incorrect.
189189
(iPersonNameResolverType: (
190190
model: Admin____relay_model_instance$data['__relay_model_instance'] | User____relay_model_instance$data['__relay_model_instance'],
191-
) => string | null);
191+
) => ?string);
192192
declare export opaque type PersonComponentFragment$fragmentType: FragmentType;
193193
export type PersonComponentFragment$data = {|
194194
+name: ?string,

compiler/crates/relay-compiler/tests/relay_compiler_integration/fixtures/resolver_on_interface_of_all_strong_model_type_including_cse.expected

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ export default ((node/*: any*/)/*: Fragment<
173173

174174
//- __generated__/PersonComponentFragment.graphql.js
175175
/**
176-
* <auto-generated> SignedSource<<f8340424d128087ea7c608c7e5e24f14>>
176+
* <auto-generated> SignedSource<<ff024ab8938010ee748b9b92881c35c4>>
177177
* @flow
178178
* @lightSyntaxTransform
179179
* @nogrep
@@ -193,7 +193,7 @@ import {name as iPersonNameResolverType} from "IPersonResolvers";
193193
// A type error here indicates that the type signature of the resolver module is incorrect.
194194
(iPersonNameResolverType: (
195195
model: Admin____relay_model_instance$data['__relay_model_instance'] | User____relay_model_instance$data['__relay_model_instance'],
196-
) => string | null);
196+
) => ?string);
197197
declare export opaque type PersonComponentFragment$fragmentType: FragmentType;
198198
export type PersonComponentFragment$data = {|
199199
+name: ?string,

compiler/crates/relay-compiler/tests/relay_compiler_integration/fixtures/resolver_on_interface_of_all_strong_model_type_with_root_fragment.expected

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ export default ((node/*: any*/)/*: Fragment<
171171

172172
//- __generated__/IPersonResolversFragment.graphql.js
173173
/**
174-
* <auto-generated> SignedSource<<3039ac5c36d275852823d4328779d54d>>
174+
* <auto-generated> SignedSource<<a8e223129204a517e8ac13f1a97bff8e>>
175175
* @flow
176176
* @lightSyntaxTransform
177177
* @nogrep
@@ -189,7 +189,7 @@ import {name as iPersonNameResolverType} from "IPersonResolvers";
189189
// A type error here indicates that the type signature of the resolver module is incorrect.
190190
(iPersonNameResolverType: (
191191
rootKey: IPersonResolversFragment$key,
192-
) => string | null);
192+
) => ?string);
193193
declare export opaque type IPersonResolversFragment$fragmentType: FragmentType;
194194
export type IPersonResolversFragment$data = {|
195195
+name: ?string,

compiler/crates/relay-compiler/tests/relay_compiler_integration/fixtures/resolver_on_interface_of_all_weak_model_type.expected

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ export default ((node/*: any*/)/*: Fragment<
102102

103103
//- __generated__/PersonComponentFragment.graphql.js
104104
/**
105-
* <auto-generated> SignedSource<<6ae25904008fca5dd338ee1e53ed18d2>>
105+
* <auto-generated> SignedSource<<fa447cade5f346d21f24221645ca4842>>
106106
* @flow
107107
* @lightSyntaxTransform
108108
* @nogrep
@@ -122,7 +122,7 @@ import {name as iPersonNameResolverType} from "IPersonResolvers";
122122
// A type error here indicates that the type signature of the resolver module is incorrect.
123123
(iPersonNameResolverType: (
124124
model: Admin____relay_model_instance$data['__relay_model_instance'] | User____relay_model_instance$data['__relay_model_instance'],
125-
) => string | null);
125+
) => ?string);
126126
declare export opaque type PersonComponentFragment$fragmentType: FragmentType;
127127
export type PersonComponentFragment$data = {|
128128
+name: ?string,

0 commit comments

Comments
 (0)