OLD | NEW |
1 library googleapis.datastore.v1.test; | 1 library googleapis.datastore.v1.test; |
2 | 2 |
3 import "dart:core" as core; | 3 import "dart:core" as core; |
4 import "dart:collection" as collection; | 4 import "dart:collection" as collection; |
5 import "dart:async" as async; | 5 import "dart:async" as async; |
6 import "dart:convert" as convert; | 6 import "dart:convert" as convert; |
7 | 7 |
8 import 'package:http/http.dart' as http; | 8 import 'package:http/http.dart' as http; |
9 import 'package:http/testing.dart' as http_testing; | 9 import 'package:http/testing.dart' as http_testing; |
10 import 'package:test/test.dart' as unittest; | 10 import 'package:test/test.dart' as unittest; |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
44 } | 44 } |
45 } | 45 } |
46 } | 46 } |
47 | 47 |
48 http.StreamedResponse stringResponse( | 48 http.StreamedResponse stringResponse( |
49 core.int status, core.Map<core.String, core.String> headers, core.String bod
y) { | 49 core.int status, core.Map<core.String, core.String> headers, core.String bod
y) { |
50 var stream = new async.Stream.fromIterable([convert.UTF8.encode(body)]); | 50 var stream = new async.Stream.fromIterable([convert.UTF8.encode(body)]); |
51 return new http.StreamedResponse(stream, status, headers: headers); | 51 return new http.StreamedResponse(stream, status, headers: headers); |
52 } | 52 } |
53 | 53 |
54 buildUnnamed625() { | 54 buildUnnamed631() { |
55 var o = new core.List<api.Key>(); | 55 var o = new core.List<api.Key>(); |
56 o.add(buildKey()); | 56 o.add(buildKey()); |
57 o.add(buildKey()); | 57 o.add(buildKey()); |
58 return o; | 58 return o; |
59 } | 59 } |
60 | 60 |
61 checkUnnamed625(core.List<api.Key> o) { | 61 checkUnnamed631(core.List<api.Key> o) { |
62 unittest.expect(o, unittest.hasLength(2)); | 62 unittest.expect(o, unittest.hasLength(2)); |
63 checkKey(o[0]); | 63 checkKey(o[0]); |
64 checkKey(o[1]); | 64 checkKey(o[1]); |
65 } | 65 } |
66 | 66 |
67 core.int buildCounterAllocateIdsRequest = 0; | 67 core.int buildCounterAllocateIdsRequest = 0; |
68 buildAllocateIdsRequest() { | 68 buildAllocateIdsRequest() { |
69 var o = new api.AllocateIdsRequest(); | 69 var o = new api.AllocateIdsRequest(); |
70 buildCounterAllocateIdsRequest++; | 70 buildCounterAllocateIdsRequest++; |
71 if (buildCounterAllocateIdsRequest < 3) { | 71 if (buildCounterAllocateIdsRequest < 3) { |
72 o.keys = buildUnnamed625(); | 72 o.keys = buildUnnamed631(); |
73 } | 73 } |
74 buildCounterAllocateIdsRequest--; | 74 buildCounterAllocateIdsRequest--; |
75 return o; | 75 return o; |
76 } | 76 } |
77 | 77 |
78 checkAllocateIdsRequest(api.AllocateIdsRequest o) { | 78 checkAllocateIdsRequest(api.AllocateIdsRequest o) { |
79 buildCounterAllocateIdsRequest++; | 79 buildCounterAllocateIdsRequest++; |
80 if (buildCounterAllocateIdsRequest < 3) { | 80 if (buildCounterAllocateIdsRequest < 3) { |
81 checkUnnamed625(o.keys); | 81 checkUnnamed631(o.keys); |
82 } | 82 } |
83 buildCounterAllocateIdsRequest--; | 83 buildCounterAllocateIdsRequest--; |
84 } | 84 } |
85 | 85 |
86 buildUnnamed626() { | 86 buildUnnamed632() { |
87 var o = new core.List<api.Key>(); | 87 var o = new core.List<api.Key>(); |
88 o.add(buildKey()); | 88 o.add(buildKey()); |
89 o.add(buildKey()); | 89 o.add(buildKey()); |
90 return o; | 90 return o; |
91 } | 91 } |
92 | 92 |
93 checkUnnamed626(core.List<api.Key> o) { | 93 checkUnnamed632(core.List<api.Key> o) { |
94 unittest.expect(o, unittest.hasLength(2)); | 94 unittest.expect(o, unittest.hasLength(2)); |
95 checkKey(o[0]); | 95 checkKey(o[0]); |
96 checkKey(o[1]); | 96 checkKey(o[1]); |
97 } | 97 } |
98 | 98 |
99 core.int buildCounterAllocateIdsResponse = 0; | 99 core.int buildCounterAllocateIdsResponse = 0; |
100 buildAllocateIdsResponse() { | 100 buildAllocateIdsResponse() { |
101 var o = new api.AllocateIdsResponse(); | 101 var o = new api.AllocateIdsResponse(); |
102 buildCounterAllocateIdsResponse++; | 102 buildCounterAllocateIdsResponse++; |
103 if (buildCounterAllocateIdsResponse < 3) { | 103 if (buildCounterAllocateIdsResponse < 3) { |
104 o.keys = buildUnnamed626(); | 104 o.keys = buildUnnamed632(); |
105 } | 105 } |
106 buildCounterAllocateIdsResponse--; | 106 buildCounterAllocateIdsResponse--; |
107 return o; | 107 return o; |
108 } | 108 } |
109 | 109 |
110 checkAllocateIdsResponse(api.AllocateIdsResponse o) { | 110 checkAllocateIdsResponse(api.AllocateIdsResponse o) { |
111 buildCounterAllocateIdsResponse++; | 111 buildCounterAllocateIdsResponse++; |
112 if (buildCounterAllocateIdsResponse < 3) { | 112 if (buildCounterAllocateIdsResponse < 3) { |
113 checkUnnamed626(o.keys); | 113 checkUnnamed632(o.keys); |
114 } | 114 } |
115 buildCounterAllocateIdsResponse--; | 115 buildCounterAllocateIdsResponse--; |
116 } | 116 } |
117 | 117 |
118 buildUnnamed627() { | 118 buildUnnamed633() { |
119 var o = new core.List<api.Value>(); | 119 var o = new core.List<api.Value>(); |
120 o.add(buildValue()); | 120 o.add(buildValue()); |
121 o.add(buildValue()); | 121 o.add(buildValue()); |
122 return o; | 122 return o; |
123 } | 123 } |
124 | 124 |
125 checkUnnamed627(core.List<api.Value> o) { | 125 checkUnnamed633(core.List<api.Value> o) { |
126 unittest.expect(o, unittest.hasLength(2)); | 126 unittest.expect(o, unittest.hasLength(2)); |
127 checkValue(o[0]); | 127 checkValue(o[0]); |
128 checkValue(o[1]); | 128 checkValue(o[1]); |
129 } | 129 } |
130 | 130 |
131 core.int buildCounterArrayValue = 0; | 131 core.int buildCounterArrayValue = 0; |
132 buildArrayValue() { | 132 buildArrayValue() { |
133 var o = new api.ArrayValue(); | 133 var o = new api.ArrayValue(); |
134 buildCounterArrayValue++; | 134 buildCounterArrayValue++; |
135 if (buildCounterArrayValue < 3) { | 135 if (buildCounterArrayValue < 3) { |
136 o.values = buildUnnamed627(); | 136 o.values = buildUnnamed633(); |
137 } | 137 } |
138 buildCounterArrayValue--; | 138 buildCounterArrayValue--; |
139 return o; | 139 return o; |
140 } | 140 } |
141 | 141 |
142 checkArrayValue(api.ArrayValue o) { | 142 checkArrayValue(api.ArrayValue o) { |
143 buildCounterArrayValue++; | 143 buildCounterArrayValue++; |
144 if (buildCounterArrayValue < 3) { | 144 if (buildCounterArrayValue < 3) { |
145 checkUnnamed627(o.values); | 145 checkUnnamed633(o.values); |
146 } | 146 } |
147 buildCounterArrayValue--; | 147 buildCounterArrayValue--; |
148 } | 148 } |
149 | 149 |
150 core.int buildCounterBeginTransactionRequest = 0; | 150 core.int buildCounterBeginTransactionRequest = 0; |
151 buildBeginTransactionRequest() { | 151 buildBeginTransactionRequest() { |
152 var o = new api.BeginTransactionRequest(); | 152 var o = new api.BeginTransactionRequest(); |
153 buildCounterBeginTransactionRequest++; | 153 buildCounterBeginTransactionRequest++; |
154 if (buildCounterBeginTransactionRequest < 3) { | 154 if (buildCounterBeginTransactionRequest < 3) { |
| 155 o.transactionOptions = buildTransactionOptions(); |
155 } | 156 } |
156 buildCounterBeginTransactionRequest--; | 157 buildCounterBeginTransactionRequest--; |
157 return o; | 158 return o; |
158 } | 159 } |
159 | 160 |
160 checkBeginTransactionRequest(api.BeginTransactionRequest o) { | 161 checkBeginTransactionRequest(api.BeginTransactionRequest o) { |
161 buildCounterBeginTransactionRequest++; | 162 buildCounterBeginTransactionRequest++; |
162 if (buildCounterBeginTransactionRequest < 3) { | 163 if (buildCounterBeginTransactionRequest < 3) { |
| 164 checkTransactionOptions(o.transactionOptions); |
163 } | 165 } |
164 buildCounterBeginTransactionRequest--; | 166 buildCounterBeginTransactionRequest--; |
165 } | 167 } |
166 | 168 |
167 core.int buildCounterBeginTransactionResponse = 0; | 169 core.int buildCounterBeginTransactionResponse = 0; |
168 buildBeginTransactionResponse() { | 170 buildBeginTransactionResponse() { |
169 var o = new api.BeginTransactionResponse(); | 171 var o = new api.BeginTransactionResponse(); |
170 buildCounterBeginTransactionResponse++; | 172 buildCounterBeginTransactionResponse++; |
171 if (buildCounterBeginTransactionResponse < 3) { | 173 if (buildCounterBeginTransactionResponse < 3) { |
172 o.transaction = "foo"; | 174 o.transaction = "foo"; |
173 } | 175 } |
174 buildCounterBeginTransactionResponse--; | 176 buildCounterBeginTransactionResponse--; |
175 return o; | 177 return o; |
176 } | 178 } |
177 | 179 |
178 checkBeginTransactionResponse(api.BeginTransactionResponse o) { | 180 checkBeginTransactionResponse(api.BeginTransactionResponse o) { |
179 buildCounterBeginTransactionResponse++; | 181 buildCounterBeginTransactionResponse++; |
180 if (buildCounterBeginTransactionResponse < 3) { | 182 if (buildCounterBeginTransactionResponse < 3) { |
181 unittest.expect(o.transaction, unittest.equals('foo')); | 183 unittest.expect(o.transaction, unittest.equals('foo')); |
182 } | 184 } |
183 buildCounterBeginTransactionResponse--; | 185 buildCounterBeginTransactionResponse--; |
184 } | 186 } |
185 | 187 |
186 buildUnnamed628() { | 188 buildUnnamed634() { |
187 var o = new core.List<api.Mutation>(); | 189 var o = new core.List<api.Mutation>(); |
188 o.add(buildMutation()); | 190 o.add(buildMutation()); |
189 o.add(buildMutation()); | 191 o.add(buildMutation()); |
190 return o; | 192 return o; |
191 } | 193 } |
192 | 194 |
193 checkUnnamed628(core.List<api.Mutation> o) { | 195 checkUnnamed634(core.List<api.Mutation> o) { |
194 unittest.expect(o, unittest.hasLength(2)); | 196 unittest.expect(o, unittest.hasLength(2)); |
195 checkMutation(o[0]); | 197 checkMutation(o[0]); |
196 checkMutation(o[1]); | 198 checkMutation(o[1]); |
197 } | 199 } |
198 | 200 |
199 core.int buildCounterCommitRequest = 0; | 201 core.int buildCounterCommitRequest = 0; |
200 buildCommitRequest() { | 202 buildCommitRequest() { |
201 var o = new api.CommitRequest(); | 203 var o = new api.CommitRequest(); |
202 buildCounterCommitRequest++; | 204 buildCounterCommitRequest++; |
203 if (buildCounterCommitRequest < 3) { | 205 if (buildCounterCommitRequest < 3) { |
204 o.mode = "foo"; | 206 o.mode = "foo"; |
205 o.mutations = buildUnnamed628(); | 207 o.mutations = buildUnnamed634(); |
206 o.transaction = "foo"; | 208 o.transaction = "foo"; |
207 } | 209 } |
208 buildCounterCommitRequest--; | 210 buildCounterCommitRequest--; |
209 return o; | 211 return o; |
210 } | 212 } |
211 | 213 |
212 checkCommitRequest(api.CommitRequest o) { | 214 checkCommitRequest(api.CommitRequest o) { |
213 buildCounterCommitRequest++; | 215 buildCounterCommitRequest++; |
214 if (buildCounterCommitRequest < 3) { | 216 if (buildCounterCommitRequest < 3) { |
215 unittest.expect(o.mode, unittest.equals('foo')); | 217 unittest.expect(o.mode, unittest.equals('foo')); |
216 checkUnnamed628(o.mutations); | 218 checkUnnamed634(o.mutations); |
217 unittest.expect(o.transaction, unittest.equals('foo')); | 219 unittest.expect(o.transaction, unittest.equals('foo')); |
218 } | 220 } |
219 buildCounterCommitRequest--; | 221 buildCounterCommitRequest--; |
220 } | 222 } |
221 | 223 |
222 buildUnnamed629() { | 224 buildUnnamed635() { |
223 var o = new core.List<api.MutationResult>(); | 225 var o = new core.List<api.MutationResult>(); |
224 o.add(buildMutationResult()); | 226 o.add(buildMutationResult()); |
225 o.add(buildMutationResult()); | 227 o.add(buildMutationResult()); |
226 return o; | 228 return o; |
227 } | 229 } |
228 | 230 |
229 checkUnnamed629(core.List<api.MutationResult> o) { | 231 checkUnnamed635(core.List<api.MutationResult> o) { |
230 unittest.expect(o, unittest.hasLength(2)); | 232 unittest.expect(o, unittest.hasLength(2)); |
231 checkMutationResult(o[0]); | 233 checkMutationResult(o[0]); |
232 checkMutationResult(o[1]); | 234 checkMutationResult(o[1]); |
233 } | 235 } |
234 | 236 |
235 core.int buildCounterCommitResponse = 0; | 237 core.int buildCounterCommitResponse = 0; |
236 buildCommitResponse() { | 238 buildCommitResponse() { |
237 var o = new api.CommitResponse(); | 239 var o = new api.CommitResponse(); |
238 buildCounterCommitResponse++; | 240 buildCounterCommitResponse++; |
239 if (buildCounterCommitResponse < 3) { | 241 if (buildCounterCommitResponse < 3) { |
240 o.indexUpdates = 42; | 242 o.indexUpdates = 42; |
241 o.mutationResults = buildUnnamed629(); | 243 o.mutationResults = buildUnnamed635(); |
242 } | 244 } |
243 buildCounterCommitResponse--; | 245 buildCounterCommitResponse--; |
244 return o; | 246 return o; |
245 } | 247 } |
246 | 248 |
247 checkCommitResponse(api.CommitResponse o) { | 249 checkCommitResponse(api.CommitResponse o) { |
248 buildCounterCommitResponse++; | 250 buildCounterCommitResponse++; |
249 if (buildCounterCommitResponse < 3) { | 251 if (buildCounterCommitResponse < 3) { |
250 unittest.expect(o.indexUpdates, unittest.equals(42)); | 252 unittest.expect(o.indexUpdates, unittest.equals(42)); |
251 checkUnnamed629(o.mutationResults); | 253 checkUnnamed635(o.mutationResults); |
252 } | 254 } |
253 buildCounterCommitResponse--; | 255 buildCounterCommitResponse--; |
254 } | 256 } |
255 | 257 |
256 buildUnnamed630() { | 258 buildUnnamed636() { |
257 var o = new core.List<api.Filter>(); | 259 var o = new core.List<api.Filter>(); |
258 o.add(buildFilter()); | 260 o.add(buildFilter()); |
259 o.add(buildFilter()); | 261 o.add(buildFilter()); |
260 return o; | 262 return o; |
261 } | 263 } |
262 | 264 |
263 checkUnnamed630(core.List<api.Filter> o) { | 265 checkUnnamed636(core.List<api.Filter> o) { |
264 unittest.expect(o, unittest.hasLength(2)); | 266 unittest.expect(o, unittest.hasLength(2)); |
265 checkFilter(o[0]); | 267 checkFilter(o[0]); |
266 checkFilter(o[1]); | 268 checkFilter(o[1]); |
267 } | 269 } |
268 | 270 |
269 core.int buildCounterCompositeFilter = 0; | 271 core.int buildCounterCompositeFilter = 0; |
270 buildCompositeFilter() { | 272 buildCompositeFilter() { |
271 var o = new api.CompositeFilter(); | 273 var o = new api.CompositeFilter(); |
272 buildCounterCompositeFilter++; | 274 buildCounterCompositeFilter++; |
273 if (buildCounterCompositeFilter < 3) { | 275 if (buildCounterCompositeFilter < 3) { |
274 o.filters = buildUnnamed630(); | 276 o.filters = buildUnnamed636(); |
275 o.op = "foo"; | 277 o.op = "foo"; |
276 } | 278 } |
277 buildCounterCompositeFilter--; | 279 buildCounterCompositeFilter--; |
278 return o; | 280 return o; |
279 } | 281 } |
280 | 282 |
281 checkCompositeFilter(api.CompositeFilter o) { | 283 checkCompositeFilter(api.CompositeFilter o) { |
282 buildCounterCompositeFilter++; | 284 buildCounterCompositeFilter++; |
283 if (buildCounterCompositeFilter < 3) { | 285 if (buildCounterCompositeFilter < 3) { |
284 checkUnnamed630(o.filters); | 286 checkUnnamed636(o.filters); |
285 unittest.expect(o.op, unittest.equals('foo')); | 287 unittest.expect(o.op, unittest.equals('foo')); |
286 } | 288 } |
287 buildCounterCompositeFilter--; | 289 buildCounterCompositeFilter--; |
288 } | 290 } |
289 | 291 |
290 buildUnnamed631() { | 292 core.int buildCounterEmpty = 0; |
| 293 buildEmpty() { |
| 294 var o = new api.Empty(); |
| 295 buildCounterEmpty++; |
| 296 if (buildCounterEmpty < 3) { |
| 297 } |
| 298 buildCounterEmpty--; |
| 299 return o; |
| 300 } |
| 301 |
| 302 checkEmpty(api.Empty o) { |
| 303 buildCounterEmpty++; |
| 304 if (buildCounterEmpty < 3) { |
| 305 } |
| 306 buildCounterEmpty--; |
| 307 } |
| 308 |
| 309 buildUnnamed637() { |
291 var o = new core.Map<core.String, api.Value>(); | 310 var o = new core.Map<core.String, api.Value>(); |
292 o["x"] = buildValue(); | 311 o["x"] = buildValue(); |
293 o["y"] = buildValue(); | 312 o["y"] = buildValue(); |
294 return o; | 313 return o; |
295 } | 314 } |
296 | 315 |
297 checkUnnamed631(core.Map<core.String, api.Value> o) { | 316 checkUnnamed637(core.Map<core.String, api.Value> o) { |
298 unittest.expect(o, unittest.hasLength(2)); | 317 unittest.expect(o, unittest.hasLength(2)); |
299 checkValue(o["x"]); | 318 checkValue(o["x"]); |
300 checkValue(o["y"]); | 319 checkValue(o["y"]); |
301 } | 320 } |
302 | 321 |
303 core.int buildCounterEntity = 0; | 322 core.int buildCounterEntity = 0; |
304 buildEntity() { | 323 buildEntity() { |
305 var o = new api.Entity(); | 324 var o = new api.Entity(); |
306 buildCounterEntity++; | 325 buildCounterEntity++; |
307 if (buildCounterEntity < 3) { | 326 if (buildCounterEntity < 3) { |
308 o.key = buildKey(); | 327 o.key = buildKey(); |
309 o.properties = buildUnnamed631(); | 328 o.properties = buildUnnamed637(); |
310 } | 329 } |
311 buildCounterEntity--; | 330 buildCounterEntity--; |
312 return o; | 331 return o; |
313 } | 332 } |
314 | 333 |
315 checkEntity(api.Entity o) { | 334 checkEntity(api.Entity o) { |
316 buildCounterEntity++; | 335 buildCounterEntity++; |
317 if (buildCounterEntity < 3) { | 336 if (buildCounterEntity < 3) { |
318 checkKey(o.key); | 337 checkKey(o.key); |
319 checkUnnamed631(o.properties); | 338 checkUnnamed637(o.properties); |
320 } | 339 } |
321 buildCounterEntity--; | 340 buildCounterEntity--; |
322 } | 341 } |
323 | 342 |
324 core.int buildCounterEntityResult = 0; | 343 core.int buildCounterEntityResult = 0; |
325 buildEntityResult() { | 344 buildEntityResult() { |
326 var o = new api.EntityResult(); | 345 var o = new api.EntityResult(); |
327 buildCounterEntityResult++; | 346 buildCounterEntityResult++; |
328 if (buildCounterEntityResult < 3) { | 347 if (buildCounterEntityResult < 3) { |
329 o.cursor = "foo"; | 348 o.cursor = "foo"; |
(...skipping 28 matching lines...) Expand all Loading... |
358 | 377 |
359 checkFilter(api.Filter o) { | 378 checkFilter(api.Filter o) { |
360 buildCounterFilter++; | 379 buildCounterFilter++; |
361 if (buildCounterFilter < 3) { | 380 if (buildCounterFilter < 3) { |
362 checkCompositeFilter(o.compositeFilter); | 381 checkCompositeFilter(o.compositeFilter); |
363 checkPropertyFilter(o.propertyFilter); | 382 checkPropertyFilter(o.propertyFilter); |
364 } | 383 } |
365 buildCounterFilter--; | 384 buildCounterFilter--; |
366 } | 385 } |
367 | 386 |
368 buildUnnamed632() { | 387 buildUnnamed638() { |
| 388 var o = new core.Map<core.String, core.String>(); |
| 389 o["x"] = "foo"; |
| 390 o["y"] = "foo"; |
| 391 return o; |
| 392 } |
| 393 |
| 394 checkUnnamed638(core.Map<core.String, core.String> o) { |
| 395 unittest.expect(o, unittest.hasLength(2)); |
| 396 unittest.expect(o["x"], unittest.equals('foo')); |
| 397 unittest.expect(o["y"], unittest.equals('foo')); |
| 398 } |
| 399 |
| 400 core.int buildCounterGoogleDatastoreAdminV1beta1CommonMetadata = 0; |
| 401 buildGoogleDatastoreAdminV1beta1CommonMetadata() { |
| 402 var o = new api.GoogleDatastoreAdminV1beta1CommonMetadata(); |
| 403 buildCounterGoogleDatastoreAdminV1beta1CommonMetadata++; |
| 404 if (buildCounterGoogleDatastoreAdminV1beta1CommonMetadata < 3) { |
| 405 o.endTime = "foo"; |
| 406 o.labels = buildUnnamed638(); |
| 407 o.operationType = "foo"; |
| 408 o.startTime = "foo"; |
| 409 o.state = "foo"; |
| 410 } |
| 411 buildCounterGoogleDatastoreAdminV1beta1CommonMetadata--; |
| 412 return o; |
| 413 } |
| 414 |
| 415 checkGoogleDatastoreAdminV1beta1CommonMetadata(api.GoogleDatastoreAdminV1beta1Co
mmonMetadata o) { |
| 416 buildCounterGoogleDatastoreAdminV1beta1CommonMetadata++; |
| 417 if (buildCounterGoogleDatastoreAdminV1beta1CommonMetadata < 3) { |
| 418 unittest.expect(o.endTime, unittest.equals('foo')); |
| 419 checkUnnamed638(o.labels); |
| 420 unittest.expect(o.operationType, unittest.equals('foo')); |
| 421 unittest.expect(o.startTime, unittest.equals('foo')); |
| 422 unittest.expect(o.state, unittest.equals('foo')); |
| 423 } |
| 424 buildCounterGoogleDatastoreAdminV1beta1CommonMetadata--; |
| 425 } |
| 426 |
| 427 buildUnnamed639() { |
| 428 var o = new core.List<core.String>(); |
| 429 o.add("foo"); |
| 430 o.add("foo"); |
| 431 return o; |
| 432 } |
| 433 |
| 434 checkUnnamed639(core.List<core.String> o) { |
| 435 unittest.expect(o, unittest.hasLength(2)); |
| 436 unittest.expect(o[0], unittest.equals('foo')); |
| 437 unittest.expect(o[1], unittest.equals('foo')); |
| 438 } |
| 439 |
| 440 buildUnnamed640() { |
| 441 var o = new core.List<core.String>(); |
| 442 o.add("foo"); |
| 443 o.add("foo"); |
| 444 return o; |
| 445 } |
| 446 |
| 447 checkUnnamed640(core.List<core.String> o) { |
| 448 unittest.expect(o, unittest.hasLength(2)); |
| 449 unittest.expect(o[0], unittest.equals('foo')); |
| 450 unittest.expect(o[1], unittest.equals('foo')); |
| 451 } |
| 452 |
| 453 core.int buildCounterGoogleDatastoreAdminV1beta1EntityFilter = 0; |
| 454 buildGoogleDatastoreAdminV1beta1EntityFilter() { |
| 455 var o = new api.GoogleDatastoreAdminV1beta1EntityFilter(); |
| 456 buildCounterGoogleDatastoreAdminV1beta1EntityFilter++; |
| 457 if (buildCounterGoogleDatastoreAdminV1beta1EntityFilter < 3) { |
| 458 o.kinds = buildUnnamed639(); |
| 459 o.namespaceIds = buildUnnamed640(); |
| 460 } |
| 461 buildCounterGoogleDatastoreAdminV1beta1EntityFilter--; |
| 462 return o; |
| 463 } |
| 464 |
| 465 checkGoogleDatastoreAdminV1beta1EntityFilter(api.GoogleDatastoreAdminV1beta1Enti
tyFilter o) { |
| 466 buildCounterGoogleDatastoreAdminV1beta1EntityFilter++; |
| 467 if (buildCounterGoogleDatastoreAdminV1beta1EntityFilter < 3) { |
| 468 checkUnnamed639(o.kinds); |
| 469 checkUnnamed640(o.namespaceIds); |
| 470 } |
| 471 buildCounterGoogleDatastoreAdminV1beta1EntityFilter--; |
| 472 } |
| 473 |
| 474 core.int buildCounterGoogleDatastoreAdminV1beta1ExportEntitiesMetadata = 0; |
| 475 buildGoogleDatastoreAdminV1beta1ExportEntitiesMetadata() { |
| 476 var o = new api.GoogleDatastoreAdminV1beta1ExportEntitiesMetadata(); |
| 477 buildCounterGoogleDatastoreAdminV1beta1ExportEntitiesMetadata++; |
| 478 if (buildCounterGoogleDatastoreAdminV1beta1ExportEntitiesMetadata < 3) { |
| 479 o.common = buildGoogleDatastoreAdminV1beta1CommonMetadata(); |
| 480 o.entityFilter = buildGoogleDatastoreAdminV1beta1EntityFilter(); |
| 481 o.outputUrlPrefix = "foo"; |
| 482 o.progressBytes = buildGoogleDatastoreAdminV1beta1Progress(); |
| 483 o.progressEntities = buildGoogleDatastoreAdminV1beta1Progress(); |
| 484 } |
| 485 buildCounterGoogleDatastoreAdminV1beta1ExportEntitiesMetadata--; |
| 486 return o; |
| 487 } |
| 488 |
| 489 checkGoogleDatastoreAdminV1beta1ExportEntitiesMetadata(api.GoogleDatastoreAdminV
1beta1ExportEntitiesMetadata o) { |
| 490 buildCounterGoogleDatastoreAdminV1beta1ExportEntitiesMetadata++; |
| 491 if (buildCounterGoogleDatastoreAdminV1beta1ExportEntitiesMetadata < 3) { |
| 492 checkGoogleDatastoreAdminV1beta1CommonMetadata(o.common); |
| 493 checkGoogleDatastoreAdminV1beta1EntityFilter(o.entityFilter); |
| 494 unittest.expect(o.outputUrlPrefix, unittest.equals('foo')); |
| 495 checkGoogleDatastoreAdminV1beta1Progress(o.progressBytes); |
| 496 checkGoogleDatastoreAdminV1beta1Progress(o.progressEntities); |
| 497 } |
| 498 buildCounterGoogleDatastoreAdminV1beta1ExportEntitiesMetadata--; |
| 499 } |
| 500 |
| 501 core.int buildCounterGoogleDatastoreAdminV1beta1ExportEntitiesResponse = 0; |
| 502 buildGoogleDatastoreAdminV1beta1ExportEntitiesResponse() { |
| 503 var o = new api.GoogleDatastoreAdminV1beta1ExportEntitiesResponse(); |
| 504 buildCounterGoogleDatastoreAdminV1beta1ExportEntitiesResponse++; |
| 505 if (buildCounterGoogleDatastoreAdminV1beta1ExportEntitiesResponse < 3) { |
| 506 o.outputUrl = "foo"; |
| 507 } |
| 508 buildCounterGoogleDatastoreAdminV1beta1ExportEntitiesResponse--; |
| 509 return o; |
| 510 } |
| 511 |
| 512 checkGoogleDatastoreAdminV1beta1ExportEntitiesResponse(api.GoogleDatastoreAdminV
1beta1ExportEntitiesResponse o) { |
| 513 buildCounterGoogleDatastoreAdminV1beta1ExportEntitiesResponse++; |
| 514 if (buildCounterGoogleDatastoreAdminV1beta1ExportEntitiesResponse < 3) { |
| 515 unittest.expect(o.outputUrl, unittest.equals('foo')); |
| 516 } |
| 517 buildCounterGoogleDatastoreAdminV1beta1ExportEntitiesResponse--; |
| 518 } |
| 519 |
| 520 core.int buildCounterGoogleDatastoreAdminV1beta1ImportEntitiesMetadata = 0; |
| 521 buildGoogleDatastoreAdminV1beta1ImportEntitiesMetadata() { |
| 522 var o = new api.GoogleDatastoreAdminV1beta1ImportEntitiesMetadata(); |
| 523 buildCounterGoogleDatastoreAdminV1beta1ImportEntitiesMetadata++; |
| 524 if (buildCounterGoogleDatastoreAdminV1beta1ImportEntitiesMetadata < 3) { |
| 525 o.common = buildGoogleDatastoreAdminV1beta1CommonMetadata(); |
| 526 o.entityFilter = buildGoogleDatastoreAdminV1beta1EntityFilter(); |
| 527 o.inputUrl = "foo"; |
| 528 o.progressBytes = buildGoogleDatastoreAdminV1beta1Progress(); |
| 529 o.progressEntities = buildGoogleDatastoreAdminV1beta1Progress(); |
| 530 } |
| 531 buildCounterGoogleDatastoreAdminV1beta1ImportEntitiesMetadata--; |
| 532 return o; |
| 533 } |
| 534 |
| 535 checkGoogleDatastoreAdminV1beta1ImportEntitiesMetadata(api.GoogleDatastoreAdminV
1beta1ImportEntitiesMetadata o) { |
| 536 buildCounterGoogleDatastoreAdminV1beta1ImportEntitiesMetadata++; |
| 537 if (buildCounterGoogleDatastoreAdminV1beta1ImportEntitiesMetadata < 3) { |
| 538 checkGoogleDatastoreAdminV1beta1CommonMetadata(o.common); |
| 539 checkGoogleDatastoreAdminV1beta1EntityFilter(o.entityFilter); |
| 540 unittest.expect(o.inputUrl, unittest.equals('foo')); |
| 541 checkGoogleDatastoreAdminV1beta1Progress(o.progressBytes); |
| 542 checkGoogleDatastoreAdminV1beta1Progress(o.progressEntities); |
| 543 } |
| 544 buildCounterGoogleDatastoreAdminV1beta1ImportEntitiesMetadata--; |
| 545 } |
| 546 |
| 547 core.int buildCounterGoogleDatastoreAdminV1beta1Progress = 0; |
| 548 buildGoogleDatastoreAdminV1beta1Progress() { |
| 549 var o = new api.GoogleDatastoreAdminV1beta1Progress(); |
| 550 buildCounterGoogleDatastoreAdminV1beta1Progress++; |
| 551 if (buildCounterGoogleDatastoreAdminV1beta1Progress < 3) { |
| 552 o.workCompleted = "foo"; |
| 553 o.workEstimated = "foo"; |
| 554 } |
| 555 buildCounterGoogleDatastoreAdminV1beta1Progress--; |
| 556 return o; |
| 557 } |
| 558 |
| 559 checkGoogleDatastoreAdminV1beta1Progress(api.GoogleDatastoreAdminV1beta1Progress
o) { |
| 560 buildCounterGoogleDatastoreAdminV1beta1Progress++; |
| 561 if (buildCounterGoogleDatastoreAdminV1beta1Progress < 3) { |
| 562 unittest.expect(o.workCompleted, unittest.equals('foo')); |
| 563 unittest.expect(o.workEstimated, unittest.equals('foo')); |
| 564 } |
| 565 buildCounterGoogleDatastoreAdminV1beta1Progress--; |
| 566 } |
| 567 |
| 568 buildUnnamed641() { |
| 569 var o = new core.List<api.GoogleLongrunningOperation>(); |
| 570 o.add(buildGoogleLongrunningOperation()); |
| 571 o.add(buildGoogleLongrunningOperation()); |
| 572 return o; |
| 573 } |
| 574 |
| 575 checkUnnamed641(core.List<api.GoogleLongrunningOperation> o) { |
| 576 unittest.expect(o, unittest.hasLength(2)); |
| 577 checkGoogleLongrunningOperation(o[0]); |
| 578 checkGoogleLongrunningOperation(o[1]); |
| 579 } |
| 580 |
| 581 core.int buildCounterGoogleLongrunningListOperationsResponse = 0; |
| 582 buildGoogleLongrunningListOperationsResponse() { |
| 583 var o = new api.GoogleLongrunningListOperationsResponse(); |
| 584 buildCounterGoogleLongrunningListOperationsResponse++; |
| 585 if (buildCounterGoogleLongrunningListOperationsResponse < 3) { |
| 586 o.nextPageToken = "foo"; |
| 587 o.operations = buildUnnamed641(); |
| 588 } |
| 589 buildCounterGoogleLongrunningListOperationsResponse--; |
| 590 return o; |
| 591 } |
| 592 |
| 593 checkGoogleLongrunningListOperationsResponse(api.GoogleLongrunningListOperations
Response o) { |
| 594 buildCounterGoogleLongrunningListOperationsResponse++; |
| 595 if (buildCounterGoogleLongrunningListOperationsResponse < 3) { |
| 596 unittest.expect(o.nextPageToken, unittest.equals('foo')); |
| 597 checkUnnamed641(o.operations); |
| 598 } |
| 599 buildCounterGoogleLongrunningListOperationsResponse--; |
| 600 } |
| 601 |
| 602 buildUnnamed642() { |
| 603 var o = new core.Map<core.String, core.Object>(); |
| 604 o["x"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; |
| 605 o["y"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; |
| 606 return o; |
| 607 } |
| 608 |
| 609 checkUnnamed642(core.Map<core.String, core.Object> o) { |
| 610 unittest.expect(o, unittest.hasLength(2)); |
| 611 var casted1 = (o["x"]) as core.Map; unittest.expect(casted1, unittest.hasLengt
h(3)); unittest.expect(casted1["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted1["bool"], unittest.equals(true)); unittest.expect(casted1["string"],
unittest.equals('foo')); |
| 612 var casted2 = (o["y"]) as core.Map; unittest.expect(casted2, unittest.hasLengt
h(3)); unittest.expect(casted2["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted2["bool"], unittest.equals(true)); unittest.expect(casted2["string"],
unittest.equals('foo')); |
| 613 } |
| 614 |
| 615 buildUnnamed643() { |
| 616 var o = new core.Map<core.String, core.Object>(); |
| 617 o["x"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; |
| 618 o["y"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; |
| 619 return o; |
| 620 } |
| 621 |
| 622 checkUnnamed643(core.Map<core.String, core.Object> o) { |
| 623 unittest.expect(o, unittest.hasLength(2)); |
| 624 var casted3 = (o["x"]) as core.Map; unittest.expect(casted3, unittest.hasLengt
h(3)); unittest.expect(casted3["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted3["bool"], unittest.equals(true)); unittest.expect(casted3["string"],
unittest.equals('foo')); |
| 625 var casted4 = (o["y"]) as core.Map; unittest.expect(casted4, unittest.hasLengt
h(3)); unittest.expect(casted4["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted4["bool"], unittest.equals(true)); unittest.expect(casted4["string"],
unittest.equals('foo')); |
| 626 } |
| 627 |
| 628 core.int buildCounterGoogleLongrunningOperation = 0; |
| 629 buildGoogleLongrunningOperation() { |
| 630 var o = new api.GoogleLongrunningOperation(); |
| 631 buildCounterGoogleLongrunningOperation++; |
| 632 if (buildCounterGoogleLongrunningOperation < 3) { |
| 633 o.done = true; |
| 634 o.error = buildStatus(); |
| 635 o.metadata = buildUnnamed642(); |
| 636 o.name = "foo"; |
| 637 o.response = buildUnnamed643(); |
| 638 } |
| 639 buildCounterGoogleLongrunningOperation--; |
| 640 return o; |
| 641 } |
| 642 |
| 643 checkGoogleLongrunningOperation(api.GoogleLongrunningOperation o) { |
| 644 buildCounterGoogleLongrunningOperation++; |
| 645 if (buildCounterGoogleLongrunningOperation < 3) { |
| 646 unittest.expect(o.done, unittest.isTrue); |
| 647 checkStatus(o.error); |
| 648 checkUnnamed642(o.metadata); |
| 649 unittest.expect(o.name, unittest.equals('foo')); |
| 650 checkUnnamed643(o.response); |
| 651 } |
| 652 buildCounterGoogleLongrunningOperation--; |
| 653 } |
| 654 |
| 655 buildUnnamed644() { |
369 var o = new core.Map<core.String, api.GqlQueryParameter>(); | 656 var o = new core.Map<core.String, api.GqlQueryParameter>(); |
370 o["x"] = buildGqlQueryParameter(); | 657 o["x"] = buildGqlQueryParameter(); |
371 o["y"] = buildGqlQueryParameter(); | 658 o["y"] = buildGqlQueryParameter(); |
372 return o; | 659 return o; |
373 } | 660 } |
374 | 661 |
375 checkUnnamed632(core.Map<core.String, api.GqlQueryParameter> o) { | 662 checkUnnamed644(core.Map<core.String, api.GqlQueryParameter> o) { |
376 unittest.expect(o, unittest.hasLength(2)); | 663 unittest.expect(o, unittest.hasLength(2)); |
377 checkGqlQueryParameter(o["x"]); | 664 checkGqlQueryParameter(o["x"]); |
378 checkGqlQueryParameter(o["y"]); | 665 checkGqlQueryParameter(o["y"]); |
379 } | 666 } |
380 | 667 |
381 buildUnnamed633() { | 668 buildUnnamed645() { |
382 var o = new core.List<api.GqlQueryParameter>(); | 669 var o = new core.List<api.GqlQueryParameter>(); |
383 o.add(buildGqlQueryParameter()); | 670 o.add(buildGqlQueryParameter()); |
384 o.add(buildGqlQueryParameter()); | 671 o.add(buildGqlQueryParameter()); |
385 return o; | 672 return o; |
386 } | 673 } |
387 | 674 |
388 checkUnnamed633(core.List<api.GqlQueryParameter> o) { | 675 checkUnnamed645(core.List<api.GqlQueryParameter> o) { |
389 unittest.expect(o, unittest.hasLength(2)); | 676 unittest.expect(o, unittest.hasLength(2)); |
390 checkGqlQueryParameter(o[0]); | 677 checkGqlQueryParameter(o[0]); |
391 checkGqlQueryParameter(o[1]); | 678 checkGqlQueryParameter(o[1]); |
392 } | 679 } |
393 | 680 |
394 core.int buildCounterGqlQuery = 0; | 681 core.int buildCounterGqlQuery = 0; |
395 buildGqlQuery() { | 682 buildGqlQuery() { |
396 var o = new api.GqlQuery(); | 683 var o = new api.GqlQuery(); |
397 buildCounterGqlQuery++; | 684 buildCounterGqlQuery++; |
398 if (buildCounterGqlQuery < 3) { | 685 if (buildCounterGqlQuery < 3) { |
399 o.allowLiterals = true; | 686 o.allowLiterals = true; |
400 o.namedBindings = buildUnnamed632(); | 687 o.namedBindings = buildUnnamed644(); |
401 o.positionalBindings = buildUnnamed633(); | 688 o.positionalBindings = buildUnnamed645(); |
402 o.queryString = "foo"; | 689 o.queryString = "foo"; |
403 } | 690 } |
404 buildCounterGqlQuery--; | 691 buildCounterGqlQuery--; |
405 return o; | 692 return o; |
406 } | 693 } |
407 | 694 |
408 checkGqlQuery(api.GqlQuery o) { | 695 checkGqlQuery(api.GqlQuery o) { |
409 buildCounterGqlQuery++; | 696 buildCounterGqlQuery++; |
410 if (buildCounterGqlQuery < 3) { | 697 if (buildCounterGqlQuery < 3) { |
411 unittest.expect(o.allowLiterals, unittest.isTrue); | 698 unittest.expect(o.allowLiterals, unittest.isTrue); |
412 checkUnnamed632(o.namedBindings); | 699 checkUnnamed644(o.namedBindings); |
413 checkUnnamed633(o.positionalBindings); | 700 checkUnnamed645(o.positionalBindings); |
414 unittest.expect(o.queryString, unittest.equals('foo')); | 701 unittest.expect(o.queryString, unittest.equals('foo')); |
415 } | 702 } |
416 buildCounterGqlQuery--; | 703 buildCounterGqlQuery--; |
417 } | 704 } |
418 | 705 |
419 core.int buildCounterGqlQueryParameter = 0; | 706 core.int buildCounterGqlQueryParameter = 0; |
420 buildGqlQueryParameter() { | 707 buildGqlQueryParameter() { |
421 var o = new api.GqlQueryParameter(); | 708 var o = new api.GqlQueryParameter(); |
422 buildCounterGqlQueryParameter++; | 709 buildCounterGqlQueryParameter++; |
423 if (buildCounterGqlQueryParameter < 3) { | 710 if (buildCounterGqlQueryParameter < 3) { |
424 o.cursor = "foo"; | 711 o.cursor = "foo"; |
425 o.value = buildValue(); | 712 o.value = buildValue(); |
426 } | 713 } |
427 buildCounterGqlQueryParameter--; | 714 buildCounterGqlQueryParameter--; |
428 return o; | 715 return o; |
429 } | 716 } |
430 | 717 |
431 checkGqlQueryParameter(api.GqlQueryParameter o) { | 718 checkGqlQueryParameter(api.GqlQueryParameter o) { |
432 buildCounterGqlQueryParameter++; | 719 buildCounterGqlQueryParameter++; |
433 if (buildCounterGqlQueryParameter < 3) { | 720 if (buildCounterGqlQueryParameter < 3) { |
434 unittest.expect(o.cursor, unittest.equals('foo')); | 721 unittest.expect(o.cursor, unittest.equals('foo')); |
435 checkValue(o.value); | 722 checkValue(o.value); |
436 } | 723 } |
437 buildCounterGqlQueryParameter--; | 724 buildCounterGqlQueryParameter--; |
438 } | 725 } |
439 | 726 |
440 buildUnnamed634() { | 727 buildUnnamed646() { |
441 var o = new core.List<api.PathElement>(); | 728 var o = new core.List<api.PathElement>(); |
442 o.add(buildPathElement()); | 729 o.add(buildPathElement()); |
443 o.add(buildPathElement()); | 730 o.add(buildPathElement()); |
444 return o; | 731 return o; |
445 } | 732 } |
446 | 733 |
447 checkUnnamed634(core.List<api.PathElement> o) { | 734 checkUnnamed646(core.List<api.PathElement> o) { |
448 unittest.expect(o, unittest.hasLength(2)); | 735 unittest.expect(o, unittest.hasLength(2)); |
449 checkPathElement(o[0]); | 736 checkPathElement(o[0]); |
450 checkPathElement(o[1]); | 737 checkPathElement(o[1]); |
451 } | 738 } |
452 | 739 |
453 core.int buildCounterKey = 0; | 740 core.int buildCounterKey = 0; |
454 buildKey() { | 741 buildKey() { |
455 var o = new api.Key(); | 742 var o = new api.Key(); |
456 buildCounterKey++; | 743 buildCounterKey++; |
457 if (buildCounterKey < 3) { | 744 if (buildCounterKey < 3) { |
458 o.partitionId = buildPartitionId(); | 745 o.partitionId = buildPartitionId(); |
459 o.path = buildUnnamed634(); | 746 o.path = buildUnnamed646(); |
460 } | 747 } |
461 buildCounterKey--; | 748 buildCounterKey--; |
462 return o; | 749 return o; |
463 } | 750 } |
464 | 751 |
465 checkKey(api.Key o) { | 752 checkKey(api.Key o) { |
466 buildCounterKey++; | 753 buildCounterKey++; |
467 if (buildCounterKey < 3) { | 754 if (buildCounterKey < 3) { |
468 checkPartitionId(o.partitionId); | 755 checkPartitionId(o.partitionId); |
469 checkUnnamed634(o.path); | 756 checkUnnamed646(o.path); |
470 } | 757 } |
471 buildCounterKey--; | 758 buildCounterKey--; |
472 } | 759 } |
473 | 760 |
474 core.int buildCounterKindExpression = 0; | 761 core.int buildCounterKindExpression = 0; |
475 buildKindExpression() { | 762 buildKindExpression() { |
476 var o = new api.KindExpression(); | 763 var o = new api.KindExpression(); |
477 buildCounterKindExpression++; | 764 buildCounterKindExpression++; |
478 if (buildCounterKindExpression < 3) { | 765 if (buildCounterKindExpression < 3) { |
479 o.name = "foo"; | 766 o.name = "foo"; |
(...skipping 24 matching lines...) Expand all Loading... |
504 | 791 |
505 checkLatLng(api.LatLng o) { | 792 checkLatLng(api.LatLng o) { |
506 buildCounterLatLng++; | 793 buildCounterLatLng++; |
507 if (buildCounterLatLng < 3) { | 794 if (buildCounterLatLng < 3) { |
508 unittest.expect(o.latitude, unittest.equals(42.0)); | 795 unittest.expect(o.latitude, unittest.equals(42.0)); |
509 unittest.expect(o.longitude, unittest.equals(42.0)); | 796 unittest.expect(o.longitude, unittest.equals(42.0)); |
510 } | 797 } |
511 buildCounterLatLng--; | 798 buildCounterLatLng--; |
512 } | 799 } |
513 | 800 |
514 buildUnnamed635() { | 801 buildUnnamed647() { |
515 var o = new core.List<api.Key>(); | 802 var o = new core.List<api.Key>(); |
516 o.add(buildKey()); | 803 o.add(buildKey()); |
517 o.add(buildKey()); | 804 o.add(buildKey()); |
518 return o; | 805 return o; |
519 } | 806 } |
520 | 807 |
521 checkUnnamed635(core.List<api.Key> o) { | 808 checkUnnamed647(core.List<api.Key> o) { |
522 unittest.expect(o, unittest.hasLength(2)); | 809 unittest.expect(o, unittest.hasLength(2)); |
523 checkKey(o[0]); | 810 checkKey(o[0]); |
524 checkKey(o[1]); | 811 checkKey(o[1]); |
525 } | 812 } |
526 | 813 |
527 core.int buildCounterLookupRequest = 0; | 814 core.int buildCounterLookupRequest = 0; |
528 buildLookupRequest() { | 815 buildLookupRequest() { |
529 var o = new api.LookupRequest(); | 816 var o = new api.LookupRequest(); |
530 buildCounterLookupRequest++; | 817 buildCounterLookupRequest++; |
531 if (buildCounterLookupRequest < 3) { | 818 if (buildCounterLookupRequest < 3) { |
532 o.keys = buildUnnamed635(); | 819 o.keys = buildUnnamed647(); |
533 o.readOptions = buildReadOptions(); | 820 o.readOptions = buildReadOptions(); |
534 } | 821 } |
535 buildCounterLookupRequest--; | 822 buildCounterLookupRequest--; |
536 return o; | 823 return o; |
537 } | 824 } |
538 | 825 |
539 checkLookupRequest(api.LookupRequest o) { | 826 checkLookupRequest(api.LookupRequest o) { |
540 buildCounterLookupRequest++; | 827 buildCounterLookupRequest++; |
541 if (buildCounterLookupRequest < 3) { | 828 if (buildCounterLookupRequest < 3) { |
542 checkUnnamed635(o.keys); | 829 checkUnnamed647(o.keys); |
543 checkReadOptions(o.readOptions); | 830 checkReadOptions(o.readOptions); |
544 } | 831 } |
545 buildCounterLookupRequest--; | 832 buildCounterLookupRequest--; |
546 } | 833 } |
547 | 834 |
548 buildUnnamed636() { | 835 buildUnnamed648() { |
549 var o = new core.List<api.Key>(); | 836 var o = new core.List<api.Key>(); |
550 o.add(buildKey()); | 837 o.add(buildKey()); |
551 o.add(buildKey()); | 838 o.add(buildKey()); |
552 return o; | 839 return o; |
553 } | 840 } |
554 | 841 |
555 checkUnnamed636(core.List<api.Key> o) { | 842 checkUnnamed648(core.List<api.Key> o) { |
556 unittest.expect(o, unittest.hasLength(2)); | 843 unittest.expect(o, unittest.hasLength(2)); |
557 checkKey(o[0]); | 844 checkKey(o[0]); |
558 checkKey(o[1]); | 845 checkKey(o[1]); |
559 } | 846 } |
560 | 847 |
561 buildUnnamed637() { | 848 buildUnnamed649() { |
562 var o = new core.List<api.EntityResult>(); | 849 var o = new core.List<api.EntityResult>(); |
563 o.add(buildEntityResult()); | 850 o.add(buildEntityResult()); |
564 o.add(buildEntityResult()); | 851 o.add(buildEntityResult()); |
565 return o; | 852 return o; |
566 } | 853 } |
567 | 854 |
568 checkUnnamed637(core.List<api.EntityResult> o) { | 855 checkUnnamed649(core.List<api.EntityResult> o) { |
569 unittest.expect(o, unittest.hasLength(2)); | 856 unittest.expect(o, unittest.hasLength(2)); |
570 checkEntityResult(o[0]); | 857 checkEntityResult(o[0]); |
571 checkEntityResult(o[1]); | 858 checkEntityResult(o[1]); |
572 } | 859 } |
573 | 860 |
574 buildUnnamed638() { | 861 buildUnnamed650() { |
575 var o = new core.List<api.EntityResult>(); | 862 var o = new core.List<api.EntityResult>(); |
576 o.add(buildEntityResult()); | 863 o.add(buildEntityResult()); |
577 o.add(buildEntityResult()); | 864 o.add(buildEntityResult()); |
578 return o; | 865 return o; |
579 } | 866 } |
580 | 867 |
581 checkUnnamed638(core.List<api.EntityResult> o) { | 868 checkUnnamed650(core.List<api.EntityResult> o) { |
582 unittest.expect(o, unittest.hasLength(2)); | 869 unittest.expect(o, unittest.hasLength(2)); |
583 checkEntityResult(o[0]); | 870 checkEntityResult(o[0]); |
584 checkEntityResult(o[1]); | 871 checkEntityResult(o[1]); |
585 } | 872 } |
586 | 873 |
587 core.int buildCounterLookupResponse = 0; | 874 core.int buildCounterLookupResponse = 0; |
588 buildLookupResponse() { | 875 buildLookupResponse() { |
589 var o = new api.LookupResponse(); | 876 var o = new api.LookupResponse(); |
590 buildCounterLookupResponse++; | 877 buildCounterLookupResponse++; |
591 if (buildCounterLookupResponse < 3) { | 878 if (buildCounterLookupResponse < 3) { |
592 o.deferred = buildUnnamed636(); | 879 o.deferred = buildUnnamed648(); |
593 o.found = buildUnnamed637(); | 880 o.found = buildUnnamed649(); |
594 o.missing = buildUnnamed638(); | 881 o.missing = buildUnnamed650(); |
595 } | 882 } |
596 buildCounterLookupResponse--; | 883 buildCounterLookupResponse--; |
597 return o; | 884 return o; |
598 } | 885 } |
599 | 886 |
600 checkLookupResponse(api.LookupResponse o) { | 887 checkLookupResponse(api.LookupResponse o) { |
601 buildCounterLookupResponse++; | 888 buildCounterLookupResponse++; |
602 if (buildCounterLookupResponse < 3) { | 889 if (buildCounterLookupResponse < 3) { |
603 checkUnnamed636(o.deferred); | 890 checkUnnamed648(o.deferred); |
604 checkUnnamed637(o.found); | 891 checkUnnamed649(o.found); |
605 checkUnnamed638(o.missing); | 892 checkUnnamed650(o.missing); |
606 } | 893 } |
607 buildCounterLookupResponse--; | 894 buildCounterLookupResponse--; |
608 } | 895 } |
609 | 896 |
610 core.int buildCounterMutation = 0; | 897 core.int buildCounterMutation = 0; |
611 buildMutation() { | 898 buildMutation() { |
612 var o = new api.Mutation(); | 899 var o = new api.Mutation(); |
613 buildCounterMutation++; | 900 buildCounterMutation++; |
614 if (buildCounterMutation < 3) { | 901 if (buildCounterMutation < 3) { |
615 o.baseVersion = "foo"; | 902 o.baseVersion = "foo"; |
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
776 } | 1063 } |
777 | 1064 |
778 checkPropertyReference(api.PropertyReference o) { | 1065 checkPropertyReference(api.PropertyReference o) { |
779 buildCounterPropertyReference++; | 1066 buildCounterPropertyReference++; |
780 if (buildCounterPropertyReference < 3) { | 1067 if (buildCounterPropertyReference < 3) { |
781 unittest.expect(o.name, unittest.equals('foo')); | 1068 unittest.expect(o.name, unittest.equals('foo')); |
782 } | 1069 } |
783 buildCounterPropertyReference--; | 1070 buildCounterPropertyReference--; |
784 } | 1071 } |
785 | 1072 |
786 buildUnnamed639() { | 1073 buildUnnamed651() { |
787 var o = new core.List<api.PropertyReference>(); | 1074 var o = new core.List<api.PropertyReference>(); |
788 o.add(buildPropertyReference()); | 1075 o.add(buildPropertyReference()); |
789 o.add(buildPropertyReference()); | 1076 o.add(buildPropertyReference()); |
790 return o; | 1077 return o; |
791 } | 1078 } |
792 | 1079 |
793 checkUnnamed639(core.List<api.PropertyReference> o) { | 1080 checkUnnamed651(core.List<api.PropertyReference> o) { |
794 unittest.expect(o, unittest.hasLength(2)); | 1081 unittest.expect(o, unittest.hasLength(2)); |
795 checkPropertyReference(o[0]); | 1082 checkPropertyReference(o[0]); |
796 checkPropertyReference(o[1]); | 1083 checkPropertyReference(o[1]); |
797 } | 1084 } |
798 | 1085 |
799 buildUnnamed640() { | 1086 buildUnnamed652() { |
800 var o = new core.List<api.KindExpression>(); | 1087 var o = new core.List<api.KindExpression>(); |
801 o.add(buildKindExpression()); | 1088 o.add(buildKindExpression()); |
802 o.add(buildKindExpression()); | 1089 o.add(buildKindExpression()); |
803 return o; | 1090 return o; |
804 } | 1091 } |
805 | 1092 |
806 checkUnnamed640(core.List<api.KindExpression> o) { | 1093 checkUnnamed652(core.List<api.KindExpression> o) { |
807 unittest.expect(o, unittest.hasLength(2)); | 1094 unittest.expect(o, unittest.hasLength(2)); |
808 checkKindExpression(o[0]); | 1095 checkKindExpression(o[0]); |
809 checkKindExpression(o[1]); | 1096 checkKindExpression(o[1]); |
810 } | 1097 } |
811 | 1098 |
812 buildUnnamed641() { | 1099 buildUnnamed653() { |
813 var o = new core.List<api.PropertyOrder>(); | 1100 var o = new core.List<api.PropertyOrder>(); |
814 o.add(buildPropertyOrder()); | 1101 o.add(buildPropertyOrder()); |
815 o.add(buildPropertyOrder()); | 1102 o.add(buildPropertyOrder()); |
816 return o; | 1103 return o; |
817 } | 1104 } |
818 | 1105 |
819 checkUnnamed641(core.List<api.PropertyOrder> o) { | 1106 checkUnnamed653(core.List<api.PropertyOrder> o) { |
820 unittest.expect(o, unittest.hasLength(2)); | 1107 unittest.expect(o, unittest.hasLength(2)); |
821 checkPropertyOrder(o[0]); | 1108 checkPropertyOrder(o[0]); |
822 checkPropertyOrder(o[1]); | 1109 checkPropertyOrder(o[1]); |
823 } | 1110 } |
824 | 1111 |
825 buildUnnamed642() { | 1112 buildUnnamed654() { |
826 var o = new core.List<api.Projection>(); | 1113 var o = new core.List<api.Projection>(); |
827 o.add(buildProjection()); | 1114 o.add(buildProjection()); |
828 o.add(buildProjection()); | 1115 o.add(buildProjection()); |
829 return o; | 1116 return o; |
830 } | 1117 } |
831 | 1118 |
832 checkUnnamed642(core.List<api.Projection> o) { | 1119 checkUnnamed654(core.List<api.Projection> o) { |
833 unittest.expect(o, unittest.hasLength(2)); | 1120 unittest.expect(o, unittest.hasLength(2)); |
834 checkProjection(o[0]); | 1121 checkProjection(o[0]); |
835 checkProjection(o[1]); | 1122 checkProjection(o[1]); |
836 } | 1123 } |
837 | 1124 |
838 core.int buildCounterQuery = 0; | 1125 core.int buildCounterQuery = 0; |
839 buildQuery() { | 1126 buildQuery() { |
840 var o = new api.Query(); | 1127 var o = new api.Query(); |
841 buildCounterQuery++; | 1128 buildCounterQuery++; |
842 if (buildCounterQuery < 3) { | 1129 if (buildCounterQuery < 3) { |
843 o.distinctOn = buildUnnamed639(); | 1130 o.distinctOn = buildUnnamed651(); |
844 o.endCursor = "foo"; | 1131 o.endCursor = "foo"; |
845 o.filter = buildFilter(); | 1132 o.filter = buildFilter(); |
846 o.kind = buildUnnamed640(); | 1133 o.kind = buildUnnamed652(); |
847 o.limit = 42; | 1134 o.limit = 42; |
848 o.offset = 42; | 1135 o.offset = 42; |
849 o.order = buildUnnamed641(); | 1136 o.order = buildUnnamed653(); |
850 o.projection = buildUnnamed642(); | 1137 o.projection = buildUnnamed654(); |
851 o.startCursor = "foo"; | 1138 o.startCursor = "foo"; |
852 } | 1139 } |
853 buildCounterQuery--; | 1140 buildCounterQuery--; |
854 return o; | 1141 return o; |
855 } | 1142 } |
856 | 1143 |
857 checkQuery(api.Query o) { | 1144 checkQuery(api.Query o) { |
858 buildCounterQuery++; | 1145 buildCounterQuery++; |
859 if (buildCounterQuery < 3) { | 1146 if (buildCounterQuery < 3) { |
860 checkUnnamed639(o.distinctOn); | 1147 checkUnnamed651(o.distinctOn); |
861 unittest.expect(o.endCursor, unittest.equals('foo')); | 1148 unittest.expect(o.endCursor, unittest.equals('foo')); |
862 checkFilter(o.filter); | 1149 checkFilter(o.filter); |
863 checkUnnamed640(o.kind); | 1150 checkUnnamed652(o.kind); |
864 unittest.expect(o.limit, unittest.equals(42)); | 1151 unittest.expect(o.limit, unittest.equals(42)); |
865 unittest.expect(o.offset, unittest.equals(42)); | 1152 unittest.expect(o.offset, unittest.equals(42)); |
866 checkUnnamed641(o.order); | 1153 checkUnnamed653(o.order); |
867 checkUnnamed642(o.projection); | 1154 checkUnnamed654(o.projection); |
868 unittest.expect(o.startCursor, unittest.equals('foo')); | 1155 unittest.expect(o.startCursor, unittest.equals('foo')); |
869 } | 1156 } |
870 buildCounterQuery--; | 1157 buildCounterQuery--; |
871 } | 1158 } |
872 | 1159 |
873 buildUnnamed643() { | 1160 buildUnnamed655() { |
874 var o = new core.List<api.EntityResult>(); | 1161 var o = new core.List<api.EntityResult>(); |
875 o.add(buildEntityResult()); | 1162 o.add(buildEntityResult()); |
876 o.add(buildEntityResult()); | 1163 o.add(buildEntityResult()); |
877 return o; | 1164 return o; |
878 } | 1165 } |
879 | 1166 |
880 checkUnnamed643(core.List<api.EntityResult> o) { | 1167 checkUnnamed655(core.List<api.EntityResult> o) { |
881 unittest.expect(o, unittest.hasLength(2)); | 1168 unittest.expect(o, unittest.hasLength(2)); |
882 checkEntityResult(o[0]); | 1169 checkEntityResult(o[0]); |
883 checkEntityResult(o[1]); | 1170 checkEntityResult(o[1]); |
884 } | 1171 } |
885 | 1172 |
886 core.int buildCounterQueryResultBatch = 0; | 1173 core.int buildCounterQueryResultBatch = 0; |
887 buildQueryResultBatch() { | 1174 buildQueryResultBatch() { |
888 var o = new api.QueryResultBatch(); | 1175 var o = new api.QueryResultBatch(); |
889 buildCounterQueryResultBatch++; | 1176 buildCounterQueryResultBatch++; |
890 if (buildCounterQueryResultBatch < 3) { | 1177 if (buildCounterQueryResultBatch < 3) { |
891 o.endCursor = "foo"; | 1178 o.endCursor = "foo"; |
892 o.entityResultType = "foo"; | 1179 o.entityResultType = "foo"; |
893 o.entityResults = buildUnnamed643(); | 1180 o.entityResults = buildUnnamed655(); |
894 o.moreResults = "foo"; | 1181 o.moreResults = "foo"; |
895 o.skippedCursor = "foo"; | 1182 o.skippedCursor = "foo"; |
896 o.skippedResults = 42; | 1183 o.skippedResults = 42; |
897 o.snapshotVersion = "foo"; | 1184 o.snapshotVersion = "foo"; |
898 } | 1185 } |
899 buildCounterQueryResultBatch--; | 1186 buildCounterQueryResultBatch--; |
900 return o; | 1187 return o; |
901 } | 1188 } |
902 | 1189 |
903 checkQueryResultBatch(api.QueryResultBatch o) { | 1190 checkQueryResultBatch(api.QueryResultBatch o) { |
904 buildCounterQueryResultBatch++; | 1191 buildCounterQueryResultBatch++; |
905 if (buildCounterQueryResultBatch < 3) { | 1192 if (buildCounterQueryResultBatch < 3) { |
906 unittest.expect(o.endCursor, unittest.equals('foo')); | 1193 unittest.expect(o.endCursor, unittest.equals('foo')); |
907 unittest.expect(o.entityResultType, unittest.equals('foo')); | 1194 unittest.expect(o.entityResultType, unittest.equals('foo')); |
908 checkUnnamed643(o.entityResults); | 1195 checkUnnamed655(o.entityResults); |
909 unittest.expect(o.moreResults, unittest.equals('foo')); | 1196 unittest.expect(o.moreResults, unittest.equals('foo')); |
910 unittest.expect(o.skippedCursor, unittest.equals('foo')); | 1197 unittest.expect(o.skippedCursor, unittest.equals('foo')); |
911 unittest.expect(o.skippedResults, unittest.equals(42)); | 1198 unittest.expect(o.skippedResults, unittest.equals(42)); |
912 unittest.expect(o.snapshotVersion, unittest.equals('foo')); | 1199 unittest.expect(o.snapshotVersion, unittest.equals('foo')); |
913 } | 1200 } |
914 buildCounterQueryResultBatch--; | 1201 buildCounterQueryResultBatch--; |
915 } | 1202 } |
916 | 1203 |
| 1204 core.int buildCounterReadOnly = 0; |
| 1205 buildReadOnly() { |
| 1206 var o = new api.ReadOnly(); |
| 1207 buildCounterReadOnly++; |
| 1208 if (buildCounterReadOnly < 3) { |
| 1209 } |
| 1210 buildCounterReadOnly--; |
| 1211 return o; |
| 1212 } |
| 1213 |
| 1214 checkReadOnly(api.ReadOnly o) { |
| 1215 buildCounterReadOnly++; |
| 1216 if (buildCounterReadOnly < 3) { |
| 1217 } |
| 1218 buildCounterReadOnly--; |
| 1219 } |
| 1220 |
917 core.int buildCounterReadOptions = 0; | 1221 core.int buildCounterReadOptions = 0; |
918 buildReadOptions() { | 1222 buildReadOptions() { |
919 var o = new api.ReadOptions(); | 1223 var o = new api.ReadOptions(); |
920 buildCounterReadOptions++; | 1224 buildCounterReadOptions++; |
921 if (buildCounterReadOptions < 3) { | 1225 if (buildCounterReadOptions < 3) { |
922 o.readConsistency = "foo"; | 1226 o.readConsistency = "foo"; |
923 o.transaction = "foo"; | 1227 o.transaction = "foo"; |
924 } | 1228 } |
925 buildCounterReadOptions--; | 1229 buildCounterReadOptions--; |
926 return o; | 1230 return o; |
927 } | 1231 } |
928 | 1232 |
929 checkReadOptions(api.ReadOptions o) { | 1233 checkReadOptions(api.ReadOptions o) { |
930 buildCounterReadOptions++; | 1234 buildCounterReadOptions++; |
931 if (buildCounterReadOptions < 3) { | 1235 if (buildCounterReadOptions < 3) { |
932 unittest.expect(o.readConsistency, unittest.equals('foo')); | 1236 unittest.expect(o.readConsistency, unittest.equals('foo')); |
933 unittest.expect(o.transaction, unittest.equals('foo')); | 1237 unittest.expect(o.transaction, unittest.equals('foo')); |
934 } | 1238 } |
935 buildCounterReadOptions--; | 1239 buildCounterReadOptions--; |
936 } | 1240 } |
937 | 1241 |
| 1242 core.int buildCounterReadWrite = 0; |
| 1243 buildReadWrite() { |
| 1244 var o = new api.ReadWrite(); |
| 1245 buildCounterReadWrite++; |
| 1246 if (buildCounterReadWrite < 3) { |
| 1247 o.previousTransaction = "foo"; |
| 1248 } |
| 1249 buildCounterReadWrite--; |
| 1250 return o; |
| 1251 } |
| 1252 |
| 1253 checkReadWrite(api.ReadWrite o) { |
| 1254 buildCounterReadWrite++; |
| 1255 if (buildCounterReadWrite < 3) { |
| 1256 unittest.expect(o.previousTransaction, unittest.equals('foo')); |
| 1257 } |
| 1258 buildCounterReadWrite--; |
| 1259 } |
| 1260 |
938 core.int buildCounterRollbackRequest = 0; | 1261 core.int buildCounterRollbackRequest = 0; |
939 buildRollbackRequest() { | 1262 buildRollbackRequest() { |
940 var o = new api.RollbackRequest(); | 1263 var o = new api.RollbackRequest(); |
941 buildCounterRollbackRequest++; | 1264 buildCounterRollbackRequest++; |
942 if (buildCounterRollbackRequest < 3) { | 1265 if (buildCounterRollbackRequest < 3) { |
943 o.transaction = "foo"; | 1266 o.transaction = "foo"; |
944 } | 1267 } |
945 buildCounterRollbackRequest--; | 1268 buildCounterRollbackRequest--; |
946 return o; | 1269 return o; |
947 } | 1270 } |
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1010 | 1333 |
1011 checkRunQueryResponse(api.RunQueryResponse o) { | 1334 checkRunQueryResponse(api.RunQueryResponse o) { |
1012 buildCounterRunQueryResponse++; | 1335 buildCounterRunQueryResponse++; |
1013 if (buildCounterRunQueryResponse < 3) { | 1336 if (buildCounterRunQueryResponse < 3) { |
1014 checkQueryResultBatch(o.batch); | 1337 checkQueryResultBatch(o.batch); |
1015 checkQuery(o.query); | 1338 checkQuery(o.query); |
1016 } | 1339 } |
1017 buildCounterRunQueryResponse--; | 1340 buildCounterRunQueryResponse--; |
1018 } | 1341 } |
1019 | 1342 |
| 1343 buildUnnamed656() { |
| 1344 var o = new core.Map<core.String, core.Object>(); |
| 1345 o["x"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; |
| 1346 o["y"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; |
| 1347 return o; |
| 1348 } |
| 1349 |
| 1350 checkUnnamed656(core.Map<core.String, core.Object> o) { |
| 1351 unittest.expect(o, unittest.hasLength(2)); |
| 1352 var casted5 = (o["x"]) as core.Map; unittest.expect(casted5, unittest.hasLengt
h(3)); unittest.expect(casted5["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted5["bool"], unittest.equals(true)); unittest.expect(casted5["string"],
unittest.equals('foo')); |
| 1353 var casted6 = (o["y"]) as core.Map; unittest.expect(casted6, unittest.hasLengt
h(3)); unittest.expect(casted6["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted6["bool"], unittest.equals(true)); unittest.expect(casted6["string"],
unittest.equals('foo')); |
| 1354 } |
| 1355 |
| 1356 buildUnnamed657() { |
| 1357 var o = new core.List<core.Map<core.String, core.Object>>(); |
| 1358 o.add(buildUnnamed656()); |
| 1359 o.add(buildUnnamed656()); |
| 1360 return o; |
| 1361 } |
| 1362 |
| 1363 checkUnnamed657(core.List<core.Map<core.String, core.Object>> o) { |
| 1364 unittest.expect(o, unittest.hasLength(2)); |
| 1365 checkUnnamed656(o[0]); |
| 1366 checkUnnamed656(o[1]); |
| 1367 } |
| 1368 |
| 1369 core.int buildCounterStatus = 0; |
| 1370 buildStatus() { |
| 1371 var o = new api.Status(); |
| 1372 buildCounterStatus++; |
| 1373 if (buildCounterStatus < 3) { |
| 1374 o.code = 42; |
| 1375 o.details = buildUnnamed657(); |
| 1376 o.message = "foo"; |
| 1377 } |
| 1378 buildCounterStatus--; |
| 1379 return o; |
| 1380 } |
| 1381 |
| 1382 checkStatus(api.Status o) { |
| 1383 buildCounterStatus++; |
| 1384 if (buildCounterStatus < 3) { |
| 1385 unittest.expect(o.code, unittest.equals(42)); |
| 1386 checkUnnamed657(o.details); |
| 1387 unittest.expect(o.message, unittest.equals('foo')); |
| 1388 } |
| 1389 buildCounterStatus--; |
| 1390 } |
| 1391 |
| 1392 core.int buildCounterTransactionOptions = 0; |
| 1393 buildTransactionOptions() { |
| 1394 var o = new api.TransactionOptions(); |
| 1395 buildCounterTransactionOptions++; |
| 1396 if (buildCounterTransactionOptions < 3) { |
| 1397 o.readOnly = buildReadOnly(); |
| 1398 o.readWrite = buildReadWrite(); |
| 1399 } |
| 1400 buildCounterTransactionOptions--; |
| 1401 return o; |
| 1402 } |
| 1403 |
| 1404 checkTransactionOptions(api.TransactionOptions o) { |
| 1405 buildCounterTransactionOptions++; |
| 1406 if (buildCounterTransactionOptions < 3) { |
| 1407 checkReadOnly(o.readOnly); |
| 1408 checkReadWrite(o.readWrite); |
| 1409 } |
| 1410 buildCounterTransactionOptions--; |
| 1411 } |
| 1412 |
1020 core.int buildCounterValue = 0; | 1413 core.int buildCounterValue = 0; |
1021 buildValue() { | 1414 buildValue() { |
1022 var o = new api.Value(); | 1415 var o = new api.Value(); |
1023 buildCounterValue++; | 1416 buildCounterValue++; |
1024 if (buildCounterValue < 3) { | 1417 if (buildCounterValue < 3) { |
1025 o.arrayValue = buildArrayValue(); | 1418 o.arrayValue = buildArrayValue(); |
1026 o.blobValue = "foo"; | 1419 o.blobValue = "foo"; |
1027 o.booleanValue = true; | 1420 o.booleanValue = true; |
1028 o.doubleValue = 42.0; | 1421 o.doubleValue = 42.0; |
1029 o.entityValue = buildEntity(); | 1422 o.entityValue = buildEntity(); |
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1127 | 1520 |
1128 unittest.group("obj-schema-CompositeFilter", () { | 1521 unittest.group("obj-schema-CompositeFilter", () { |
1129 unittest.test("to-json--from-json", () { | 1522 unittest.test("to-json--from-json", () { |
1130 var o = buildCompositeFilter(); | 1523 var o = buildCompositeFilter(); |
1131 var od = new api.CompositeFilter.fromJson(o.toJson()); | 1524 var od = new api.CompositeFilter.fromJson(o.toJson()); |
1132 checkCompositeFilter(od); | 1525 checkCompositeFilter(od); |
1133 }); | 1526 }); |
1134 }); | 1527 }); |
1135 | 1528 |
1136 | 1529 |
| 1530 unittest.group("obj-schema-Empty", () { |
| 1531 unittest.test("to-json--from-json", () { |
| 1532 var o = buildEmpty(); |
| 1533 var od = new api.Empty.fromJson(o.toJson()); |
| 1534 checkEmpty(od); |
| 1535 }); |
| 1536 }); |
| 1537 |
| 1538 |
1137 unittest.group("obj-schema-Entity", () { | 1539 unittest.group("obj-schema-Entity", () { |
1138 unittest.test("to-json--from-json", () { | 1540 unittest.test("to-json--from-json", () { |
1139 var o = buildEntity(); | 1541 var o = buildEntity(); |
1140 var od = new api.Entity.fromJson(o.toJson()); | 1542 var od = new api.Entity.fromJson(o.toJson()); |
1141 checkEntity(od); | 1543 checkEntity(od); |
1142 }); | 1544 }); |
1143 }); | 1545 }); |
1144 | 1546 |
1145 | 1547 |
1146 unittest.group("obj-schema-EntityResult", () { | 1548 unittest.group("obj-schema-EntityResult", () { |
1147 unittest.test("to-json--from-json", () { | 1549 unittest.test("to-json--from-json", () { |
1148 var o = buildEntityResult(); | 1550 var o = buildEntityResult(); |
1149 var od = new api.EntityResult.fromJson(o.toJson()); | 1551 var od = new api.EntityResult.fromJson(o.toJson()); |
1150 checkEntityResult(od); | 1552 checkEntityResult(od); |
1151 }); | 1553 }); |
1152 }); | 1554 }); |
1153 | 1555 |
1154 | 1556 |
1155 unittest.group("obj-schema-Filter", () { | 1557 unittest.group("obj-schema-Filter", () { |
1156 unittest.test("to-json--from-json", () { | 1558 unittest.test("to-json--from-json", () { |
1157 var o = buildFilter(); | 1559 var o = buildFilter(); |
1158 var od = new api.Filter.fromJson(o.toJson()); | 1560 var od = new api.Filter.fromJson(o.toJson()); |
1159 checkFilter(od); | 1561 checkFilter(od); |
1160 }); | 1562 }); |
1161 }); | 1563 }); |
1162 | 1564 |
1163 | 1565 |
| 1566 unittest.group("obj-schema-GoogleDatastoreAdminV1beta1CommonMetadata", () { |
| 1567 unittest.test("to-json--from-json", () { |
| 1568 var o = buildGoogleDatastoreAdminV1beta1CommonMetadata(); |
| 1569 var od = new api.GoogleDatastoreAdminV1beta1CommonMetadata.fromJson(o.toJs
on()); |
| 1570 checkGoogleDatastoreAdminV1beta1CommonMetadata(od); |
| 1571 }); |
| 1572 }); |
| 1573 |
| 1574 |
| 1575 unittest.group("obj-schema-GoogleDatastoreAdminV1beta1EntityFilter", () { |
| 1576 unittest.test("to-json--from-json", () { |
| 1577 var o = buildGoogleDatastoreAdminV1beta1EntityFilter(); |
| 1578 var od = new api.GoogleDatastoreAdminV1beta1EntityFilter.fromJson(o.toJson
()); |
| 1579 checkGoogleDatastoreAdminV1beta1EntityFilter(od); |
| 1580 }); |
| 1581 }); |
| 1582 |
| 1583 |
| 1584 unittest.group("obj-schema-GoogleDatastoreAdminV1beta1ExportEntitiesMetadata",
() { |
| 1585 unittest.test("to-json--from-json", () { |
| 1586 var o = buildGoogleDatastoreAdminV1beta1ExportEntitiesMetadata(); |
| 1587 var od = new api.GoogleDatastoreAdminV1beta1ExportEntitiesMetadata.fromJso
n(o.toJson()); |
| 1588 checkGoogleDatastoreAdminV1beta1ExportEntitiesMetadata(od); |
| 1589 }); |
| 1590 }); |
| 1591 |
| 1592 |
| 1593 unittest.group("obj-schema-GoogleDatastoreAdminV1beta1ExportEntitiesResponse",
() { |
| 1594 unittest.test("to-json--from-json", () { |
| 1595 var o = buildGoogleDatastoreAdminV1beta1ExportEntitiesResponse(); |
| 1596 var od = new api.GoogleDatastoreAdminV1beta1ExportEntitiesResponse.fromJso
n(o.toJson()); |
| 1597 checkGoogleDatastoreAdminV1beta1ExportEntitiesResponse(od); |
| 1598 }); |
| 1599 }); |
| 1600 |
| 1601 |
| 1602 unittest.group("obj-schema-GoogleDatastoreAdminV1beta1ImportEntitiesMetadata",
() { |
| 1603 unittest.test("to-json--from-json", () { |
| 1604 var o = buildGoogleDatastoreAdminV1beta1ImportEntitiesMetadata(); |
| 1605 var od = new api.GoogleDatastoreAdminV1beta1ImportEntitiesMetadata.fromJso
n(o.toJson()); |
| 1606 checkGoogleDatastoreAdminV1beta1ImportEntitiesMetadata(od); |
| 1607 }); |
| 1608 }); |
| 1609 |
| 1610 |
| 1611 unittest.group("obj-schema-GoogleDatastoreAdminV1beta1Progress", () { |
| 1612 unittest.test("to-json--from-json", () { |
| 1613 var o = buildGoogleDatastoreAdminV1beta1Progress(); |
| 1614 var od = new api.GoogleDatastoreAdminV1beta1Progress.fromJson(o.toJson()); |
| 1615 checkGoogleDatastoreAdminV1beta1Progress(od); |
| 1616 }); |
| 1617 }); |
| 1618 |
| 1619 |
| 1620 unittest.group("obj-schema-GoogleLongrunningListOperationsResponse", () { |
| 1621 unittest.test("to-json--from-json", () { |
| 1622 var o = buildGoogleLongrunningListOperationsResponse(); |
| 1623 var od = new api.GoogleLongrunningListOperationsResponse.fromJson(o.toJson
()); |
| 1624 checkGoogleLongrunningListOperationsResponse(od); |
| 1625 }); |
| 1626 }); |
| 1627 |
| 1628 |
| 1629 unittest.group("obj-schema-GoogleLongrunningOperation", () { |
| 1630 unittest.test("to-json--from-json", () { |
| 1631 var o = buildGoogleLongrunningOperation(); |
| 1632 var od = new api.GoogleLongrunningOperation.fromJson(o.toJson()); |
| 1633 checkGoogleLongrunningOperation(od); |
| 1634 }); |
| 1635 }); |
| 1636 |
| 1637 |
1164 unittest.group("obj-schema-GqlQuery", () { | 1638 unittest.group("obj-schema-GqlQuery", () { |
1165 unittest.test("to-json--from-json", () { | 1639 unittest.test("to-json--from-json", () { |
1166 var o = buildGqlQuery(); | 1640 var o = buildGqlQuery(); |
1167 var od = new api.GqlQuery.fromJson(o.toJson()); | 1641 var od = new api.GqlQuery.fromJson(o.toJson()); |
1168 checkGqlQuery(od); | 1642 checkGqlQuery(od); |
1169 }); | 1643 }); |
1170 }); | 1644 }); |
1171 | 1645 |
1172 | 1646 |
1173 unittest.group("obj-schema-GqlQueryParameter", () { | 1647 unittest.group("obj-schema-GqlQueryParameter", () { |
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1307 | 1781 |
1308 unittest.group("obj-schema-QueryResultBatch", () { | 1782 unittest.group("obj-schema-QueryResultBatch", () { |
1309 unittest.test("to-json--from-json", () { | 1783 unittest.test("to-json--from-json", () { |
1310 var o = buildQueryResultBatch(); | 1784 var o = buildQueryResultBatch(); |
1311 var od = new api.QueryResultBatch.fromJson(o.toJson()); | 1785 var od = new api.QueryResultBatch.fromJson(o.toJson()); |
1312 checkQueryResultBatch(od); | 1786 checkQueryResultBatch(od); |
1313 }); | 1787 }); |
1314 }); | 1788 }); |
1315 | 1789 |
1316 | 1790 |
| 1791 unittest.group("obj-schema-ReadOnly", () { |
| 1792 unittest.test("to-json--from-json", () { |
| 1793 var o = buildReadOnly(); |
| 1794 var od = new api.ReadOnly.fromJson(o.toJson()); |
| 1795 checkReadOnly(od); |
| 1796 }); |
| 1797 }); |
| 1798 |
| 1799 |
1317 unittest.group("obj-schema-ReadOptions", () { | 1800 unittest.group("obj-schema-ReadOptions", () { |
1318 unittest.test("to-json--from-json", () { | 1801 unittest.test("to-json--from-json", () { |
1319 var o = buildReadOptions(); | 1802 var o = buildReadOptions(); |
1320 var od = new api.ReadOptions.fromJson(o.toJson()); | 1803 var od = new api.ReadOptions.fromJson(o.toJson()); |
1321 checkReadOptions(od); | 1804 checkReadOptions(od); |
1322 }); | 1805 }); |
1323 }); | 1806 }); |
1324 | 1807 |
1325 | 1808 |
| 1809 unittest.group("obj-schema-ReadWrite", () { |
| 1810 unittest.test("to-json--from-json", () { |
| 1811 var o = buildReadWrite(); |
| 1812 var od = new api.ReadWrite.fromJson(o.toJson()); |
| 1813 checkReadWrite(od); |
| 1814 }); |
| 1815 }); |
| 1816 |
| 1817 |
1326 unittest.group("obj-schema-RollbackRequest", () { | 1818 unittest.group("obj-schema-RollbackRequest", () { |
1327 unittest.test("to-json--from-json", () { | 1819 unittest.test("to-json--from-json", () { |
1328 var o = buildRollbackRequest(); | 1820 var o = buildRollbackRequest(); |
1329 var od = new api.RollbackRequest.fromJson(o.toJson()); | 1821 var od = new api.RollbackRequest.fromJson(o.toJson()); |
1330 checkRollbackRequest(od); | 1822 checkRollbackRequest(od); |
1331 }); | 1823 }); |
1332 }); | 1824 }); |
1333 | 1825 |
1334 | 1826 |
1335 unittest.group("obj-schema-RollbackResponse", () { | 1827 unittest.group("obj-schema-RollbackResponse", () { |
(...skipping 16 matching lines...) Expand all Loading... |
1352 | 1844 |
1353 unittest.group("obj-schema-RunQueryResponse", () { | 1845 unittest.group("obj-schema-RunQueryResponse", () { |
1354 unittest.test("to-json--from-json", () { | 1846 unittest.test("to-json--from-json", () { |
1355 var o = buildRunQueryResponse(); | 1847 var o = buildRunQueryResponse(); |
1356 var od = new api.RunQueryResponse.fromJson(o.toJson()); | 1848 var od = new api.RunQueryResponse.fromJson(o.toJson()); |
1357 checkRunQueryResponse(od); | 1849 checkRunQueryResponse(od); |
1358 }); | 1850 }); |
1359 }); | 1851 }); |
1360 | 1852 |
1361 | 1853 |
| 1854 unittest.group("obj-schema-Status", () { |
| 1855 unittest.test("to-json--from-json", () { |
| 1856 var o = buildStatus(); |
| 1857 var od = new api.Status.fromJson(o.toJson()); |
| 1858 checkStatus(od); |
| 1859 }); |
| 1860 }); |
| 1861 |
| 1862 |
| 1863 unittest.group("obj-schema-TransactionOptions", () { |
| 1864 unittest.test("to-json--from-json", () { |
| 1865 var o = buildTransactionOptions(); |
| 1866 var od = new api.TransactionOptions.fromJson(o.toJson()); |
| 1867 checkTransactionOptions(od); |
| 1868 }); |
| 1869 }); |
| 1870 |
| 1871 |
1362 unittest.group("obj-schema-Value", () { | 1872 unittest.group("obj-schema-Value", () { |
1363 unittest.test("to-json--from-json", () { | 1873 unittest.test("to-json--from-json", () { |
1364 var o = buildValue(); | 1874 var o = buildValue(); |
1365 var od = new api.Value.fromJson(o.toJson()); | 1875 var od = new api.Value.fromJson(o.toJson()); |
1366 checkValue(od); | 1876 checkValue(od); |
1367 }); | 1877 }); |
1368 }); | 1878 }); |
1369 | 1879 |
1370 | 1880 |
1371 unittest.group("resource-ProjectsResourceApi", () { | 1881 unittest.group("resource-ProjectsResourceApi", () { |
(...skipping 323 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1695 return new async.Future.value(stringResponse(200, h, resp)); | 2205 return new async.Future.value(stringResponse(200, h, resp)); |
1696 }), true); | 2206 }), true); |
1697 res.runQuery(arg_request, arg_projectId).then(unittest.expectAsync1(((api.
RunQueryResponse response) { | 2207 res.runQuery(arg_request, arg_projectId).then(unittest.expectAsync1(((api.
RunQueryResponse response) { |
1698 checkRunQueryResponse(response); | 2208 checkRunQueryResponse(response); |
1699 }))); | 2209 }))); |
1700 }); | 2210 }); |
1701 | 2211 |
1702 }); | 2212 }); |
1703 | 2213 |
1704 | 2214 |
| 2215 unittest.group("resource-ProjectsOperationsResourceApi", () { |
| 2216 unittest.test("method--cancel", () { |
| 2217 |
| 2218 var mock = new HttpServerMock(); |
| 2219 api.ProjectsOperationsResourceApi res = new api.DatastoreApi(mock).project
s.operations; |
| 2220 var arg_name = "foo"; |
| 2221 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
| 2222 var path = (req.url).path; |
| 2223 var pathOffset = 0; |
| 2224 var index; |
| 2225 var subPart; |
| 2226 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
| 2227 pathOffset += 1; |
| 2228 unittest.expect(path.substring(pathOffset, pathOffset + 3), unittest.equ
als("v1/")); |
| 2229 pathOffset += 3; |
| 2230 // NOTE: We cannot test reserved expansions due to the inability to reve
rse the operation; |
| 2231 |
| 2232 var query = (req.url).query; |
| 2233 var queryOffset = 0; |
| 2234 var queryMap = {}; |
| 2235 addQueryParam(n, v) => queryMap.putIfAbsent(n, () => []).add(v); |
| 2236 parseBool(n) { |
| 2237 if (n == "true") return true; |
| 2238 if (n == "false") return false; |
| 2239 if (n == null) return null; |
| 2240 throw new core.ArgumentError("Invalid boolean: $n"); |
| 2241 } |
| 2242 if (query.length > 0) { |
| 2243 for (var part in query.split("&")) { |
| 2244 var keyvalue = part.split("="); |
| 2245 addQueryParam(core.Uri.decodeQueryComponent(keyvalue[0]), core.Uri.d
ecodeQueryComponent(keyvalue[1])); |
| 2246 } |
| 2247 } |
| 2248 |
| 2249 |
| 2250 var h = { |
| 2251 "content-type" : "application/json; charset=utf-8", |
| 2252 }; |
| 2253 var resp = convert.JSON.encode(buildEmpty()); |
| 2254 return new async.Future.value(stringResponse(200, h, resp)); |
| 2255 }), true); |
| 2256 res.cancel(arg_name).then(unittest.expectAsync1(((api.Empty response) { |
| 2257 checkEmpty(response); |
| 2258 }))); |
| 2259 }); |
| 2260 |
| 2261 unittest.test("method--delete", () { |
| 2262 |
| 2263 var mock = new HttpServerMock(); |
| 2264 api.ProjectsOperationsResourceApi res = new api.DatastoreApi(mock).project
s.operations; |
| 2265 var arg_name = "foo"; |
| 2266 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
| 2267 var path = (req.url).path; |
| 2268 var pathOffset = 0; |
| 2269 var index; |
| 2270 var subPart; |
| 2271 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
| 2272 pathOffset += 1; |
| 2273 unittest.expect(path.substring(pathOffset, pathOffset + 3), unittest.equ
als("v1/")); |
| 2274 pathOffset += 3; |
| 2275 // NOTE: We cannot test reserved expansions due to the inability to reve
rse the operation; |
| 2276 |
| 2277 var query = (req.url).query; |
| 2278 var queryOffset = 0; |
| 2279 var queryMap = {}; |
| 2280 addQueryParam(n, v) => queryMap.putIfAbsent(n, () => []).add(v); |
| 2281 parseBool(n) { |
| 2282 if (n == "true") return true; |
| 2283 if (n == "false") return false; |
| 2284 if (n == null) return null; |
| 2285 throw new core.ArgumentError("Invalid boolean: $n"); |
| 2286 } |
| 2287 if (query.length > 0) { |
| 2288 for (var part in query.split("&")) { |
| 2289 var keyvalue = part.split("="); |
| 2290 addQueryParam(core.Uri.decodeQueryComponent(keyvalue[0]), core.Uri.d
ecodeQueryComponent(keyvalue[1])); |
| 2291 } |
| 2292 } |
| 2293 |
| 2294 |
| 2295 var h = { |
| 2296 "content-type" : "application/json; charset=utf-8", |
| 2297 }; |
| 2298 var resp = convert.JSON.encode(buildEmpty()); |
| 2299 return new async.Future.value(stringResponse(200, h, resp)); |
| 2300 }), true); |
| 2301 res.delete(arg_name).then(unittest.expectAsync1(((api.Empty response) { |
| 2302 checkEmpty(response); |
| 2303 }))); |
| 2304 }); |
| 2305 |
| 2306 unittest.test("method--get", () { |
| 2307 |
| 2308 var mock = new HttpServerMock(); |
| 2309 api.ProjectsOperationsResourceApi res = new api.DatastoreApi(mock).project
s.operations; |
| 2310 var arg_name = "foo"; |
| 2311 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
| 2312 var path = (req.url).path; |
| 2313 var pathOffset = 0; |
| 2314 var index; |
| 2315 var subPart; |
| 2316 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
| 2317 pathOffset += 1; |
| 2318 unittest.expect(path.substring(pathOffset, pathOffset + 3), unittest.equ
als("v1/")); |
| 2319 pathOffset += 3; |
| 2320 // NOTE: We cannot test reserved expansions due to the inability to reve
rse the operation; |
| 2321 |
| 2322 var query = (req.url).query; |
| 2323 var queryOffset = 0; |
| 2324 var queryMap = {}; |
| 2325 addQueryParam(n, v) => queryMap.putIfAbsent(n, () => []).add(v); |
| 2326 parseBool(n) { |
| 2327 if (n == "true") return true; |
| 2328 if (n == "false") return false; |
| 2329 if (n == null) return null; |
| 2330 throw new core.ArgumentError("Invalid boolean: $n"); |
| 2331 } |
| 2332 if (query.length > 0) { |
| 2333 for (var part in query.split("&")) { |
| 2334 var keyvalue = part.split("="); |
| 2335 addQueryParam(core.Uri.decodeQueryComponent(keyvalue[0]), core.Uri.d
ecodeQueryComponent(keyvalue[1])); |
| 2336 } |
| 2337 } |
| 2338 |
| 2339 |
| 2340 var h = { |
| 2341 "content-type" : "application/json; charset=utf-8", |
| 2342 }; |
| 2343 var resp = convert.JSON.encode(buildGoogleLongrunningOperation()); |
| 2344 return new async.Future.value(stringResponse(200, h, resp)); |
| 2345 }), true); |
| 2346 res.get(arg_name).then(unittest.expectAsync1(((api.GoogleLongrunningOperat
ion response) { |
| 2347 checkGoogleLongrunningOperation(response); |
| 2348 }))); |
| 2349 }); |
| 2350 |
| 2351 unittest.test("method--list", () { |
| 2352 |
| 2353 var mock = new HttpServerMock(); |
| 2354 api.ProjectsOperationsResourceApi res = new api.DatastoreApi(mock).project
s.operations; |
| 2355 var arg_name = "foo"; |
| 2356 var arg_pageSize = 42; |
| 2357 var arg_filter = "foo"; |
| 2358 var arg_pageToken = "foo"; |
| 2359 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
| 2360 var path = (req.url).path; |
| 2361 var pathOffset = 0; |
| 2362 var index; |
| 2363 var subPart; |
| 2364 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
| 2365 pathOffset += 1; |
| 2366 unittest.expect(path.substring(pathOffset, pathOffset + 3), unittest.equ
als("v1/")); |
| 2367 pathOffset += 3; |
| 2368 // NOTE: We cannot test reserved expansions due to the inability to reve
rse the operation; |
| 2369 |
| 2370 var query = (req.url).query; |
| 2371 var queryOffset = 0; |
| 2372 var queryMap = {}; |
| 2373 addQueryParam(n, v) => queryMap.putIfAbsent(n, () => []).add(v); |
| 2374 parseBool(n) { |
| 2375 if (n == "true") return true; |
| 2376 if (n == "false") return false; |
| 2377 if (n == null) return null; |
| 2378 throw new core.ArgumentError("Invalid boolean: $n"); |
| 2379 } |
| 2380 if (query.length > 0) { |
| 2381 for (var part in query.split("&")) { |
| 2382 var keyvalue = part.split("="); |
| 2383 addQueryParam(core.Uri.decodeQueryComponent(keyvalue[0]), core.Uri.d
ecodeQueryComponent(keyvalue[1])); |
| 2384 } |
| 2385 } |
| 2386 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); |
| 2387 unittest.expect(queryMap["filter"].first, unittest.equals(arg_filter)); |
| 2388 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); |
| 2389 |
| 2390 |
| 2391 var h = { |
| 2392 "content-type" : "application/json; charset=utf-8", |
| 2393 }; |
| 2394 var resp = convert.JSON.encode(buildGoogleLongrunningListOperationsRespo
nse()); |
| 2395 return new async.Future.value(stringResponse(200, h, resp)); |
| 2396 }), true); |
| 2397 res.list(arg_name, pageSize: arg_pageSize, filter: arg_filter, pageToken:
arg_pageToken).then(unittest.expectAsync1(((api.GoogleLongrunningListOperationsR
esponse response) { |
| 2398 checkGoogleLongrunningListOperationsResponse(response); |
| 2399 }))); |
| 2400 }); |
| 2401 |
| 2402 }); |
| 2403 |
| 2404 |
1705 } | 2405 } |
1706 | 2406 |
OLD | NEW |