OLD | NEW |
1 library googleapis.androidpublisher.v2.test; | 1 library googleapis.androidpublisher.v2.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:unittest/unittest.dart' as unittest; | 10 import 'package:test/test.dart' as unittest; |
11 | 11 |
12 import 'package:googleapis/androidpublisher/v2.dart' as api; | 12 import 'package:googleapis/androidpublisher/v2.dart' as api; |
13 | 13 |
14 class HttpServerMock extends http.BaseClient { | 14 class HttpServerMock extends http.BaseClient { |
15 core.Function _callback; | 15 core.Function _callback; |
16 core.bool _expectJson; | 16 core.bool _expectJson; |
17 | 17 |
18 void register(core.Function callback, core.bool expectJson) { | 18 void register(core.Function callback, core.bool expectJson) { |
19 _callback = callback; | 19 _callback = callback; |
20 _expectJson = expectJson; | 20 _expectJson = expectJson; |
(...skipping 18 matching lines...) Expand all Loading... |
39 } else { | 39 } else { |
40 return stream.toBytes().then((data) { | 40 return stream.toBytes().then((data) { |
41 return _callback(request, data); | 41 return _callback(request, data); |
42 }); | 42 }); |
43 } | 43 } |
44 } | 44 } |
45 } | 45 } |
46 } | 46 } |
47 | 47 |
48 http.StreamedResponse stringResponse( | 48 http.StreamedResponse stringResponse( |
49 core.int status, core.Map headers, core.String body) { | 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 core.int buildCounterApk = 0; | 54 core.int buildCounterApk = 0; |
55 buildApk() { | 55 buildApk() { |
56 var o = new api.Apk(); | 56 var o = new api.Apk(); |
57 buildCounterApk++; | 57 buildCounterApk++; |
58 if (buildCounterApk < 3) { | 58 if (buildCounterApk < 3) { |
59 o.binary = buildApkBinary(); | 59 o.binary = buildApkBinary(); |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
105 | 105 |
106 checkApkListing(api.ApkListing o) { | 106 checkApkListing(api.ApkListing o) { |
107 buildCounterApkListing++; | 107 buildCounterApkListing++; |
108 if (buildCounterApkListing < 3) { | 108 if (buildCounterApkListing < 3) { |
109 unittest.expect(o.language, unittest.equals('foo')); | 109 unittest.expect(o.language, unittest.equals('foo')); |
110 unittest.expect(o.recentChanges, unittest.equals('foo')); | 110 unittest.expect(o.recentChanges, unittest.equals('foo')); |
111 } | 111 } |
112 buildCounterApkListing--; | 112 buildCounterApkListing--; |
113 } | 113 } |
114 | 114 |
115 buildUnnamed2899() { | 115 buildUnnamed2369() { |
116 var o = new core.List<api.ApkListing>(); | 116 var o = new core.List<api.ApkListing>(); |
117 o.add(buildApkListing()); | 117 o.add(buildApkListing()); |
118 o.add(buildApkListing()); | 118 o.add(buildApkListing()); |
119 return o; | 119 return o; |
120 } | 120 } |
121 | 121 |
122 checkUnnamed2899(core.List<api.ApkListing> o) { | 122 checkUnnamed2369(core.List<api.ApkListing> o) { |
123 unittest.expect(o, unittest.hasLength(2)); | 123 unittest.expect(o, unittest.hasLength(2)); |
124 checkApkListing(o[0]); | 124 checkApkListing(o[0]); |
125 checkApkListing(o[1]); | 125 checkApkListing(o[1]); |
126 } | 126 } |
127 | 127 |
128 core.int buildCounterApkListingsListResponse = 0; | 128 core.int buildCounterApkListingsListResponse = 0; |
129 buildApkListingsListResponse() { | 129 buildApkListingsListResponse() { |
130 var o = new api.ApkListingsListResponse(); | 130 var o = new api.ApkListingsListResponse(); |
131 buildCounterApkListingsListResponse++; | 131 buildCounterApkListingsListResponse++; |
132 if (buildCounterApkListingsListResponse < 3) { | 132 if (buildCounterApkListingsListResponse < 3) { |
133 o.kind = "foo"; | 133 o.kind = "foo"; |
134 o.listings = buildUnnamed2899(); | 134 o.listings = buildUnnamed2369(); |
135 } | 135 } |
136 buildCounterApkListingsListResponse--; | 136 buildCounterApkListingsListResponse--; |
137 return o; | 137 return o; |
138 } | 138 } |
139 | 139 |
140 checkApkListingsListResponse(api.ApkListingsListResponse o) { | 140 checkApkListingsListResponse(api.ApkListingsListResponse o) { |
141 buildCounterApkListingsListResponse++; | 141 buildCounterApkListingsListResponse++; |
142 if (buildCounterApkListingsListResponse < 3) { | 142 if (buildCounterApkListingsListResponse < 3) { |
143 unittest.expect(o.kind, unittest.equals('foo')); | 143 unittest.expect(o.kind, unittest.equals('foo')); |
144 checkUnnamed2899(o.listings); | 144 checkUnnamed2369(o.listings); |
145 } | 145 } |
146 buildCounterApkListingsListResponse--; | 146 buildCounterApkListingsListResponse--; |
147 } | 147 } |
148 | 148 |
149 core.int buildCounterApksAddExternallyHostedRequest = 0; | 149 core.int buildCounterApksAddExternallyHostedRequest = 0; |
150 buildApksAddExternallyHostedRequest() { | 150 buildApksAddExternallyHostedRequest() { |
151 var o = new api.ApksAddExternallyHostedRequest(); | 151 var o = new api.ApksAddExternallyHostedRequest(); |
152 buildCounterApksAddExternallyHostedRequest++; | 152 buildCounterApksAddExternallyHostedRequest++; |
153 if (buildCounterApksAddExternallyHostedRequest < 3) { | 153 if (buildCounterApksAddExternallyHostedRequest < 3) { |
154 o.externallyHostedApk = buildExternallyHostedApk(); | 154 o.externallyHostedApk = buildExternallyHostedApk(); |
(...skipping 22 matching lines...) Expand all Loading... |
177 } | 177 } |
178 | 178 |
179 checkApksAddExternallyHostedResponse(api.ApksAddExternallyHostedResponse o) { | 179 checkApksAddExternallyHostedResponse(api.ApksAddExternallyHostedResponse o) { |
180 buildCounterApksAddExternallyHostedResponse++; | 180 buildCounterApksAddExternallyHostedResponse++; |
181 if (buildCounterApksAddExternallyHostedResponse < 3) { | 181 if (buildCounterApksAddExternallyHostedResponse < 3) { |
182 checkExternallyHostedApk(o.externallyHostedApk); | 182 checkExternallyHostedApk(o.externallyHostedApk); |
183 } | 183 } |
184 buildCounterApksAddExternallyHostedResponse--; | 184 buildCounterApksAddExternallyHostedResponse--; |
185 } | 185 } |
186 | 186 |
187 buildUnnamed2900() { | 187 buildUnnamed2370() { |
188 var o = new core.List<api.Apk>(); | 188 var o = new core.List<api.Apk>(); |
189 o.add(buildApk()); | 189 o.add(buildApk()); |
190 o.add(buildApk()); | 190 o.add(buildApk()); |
191 return o; | 191 return o; |
192 } | 192 } |
193 | 193 |
194 checkUnnamed2900(core.List<api.Apk> o) { | 194 checkUnnamed2370(core.List<api.Apk> o) { |
195 unittest.expect(o, unittest.hasLength(2)); | 195 unittest.expect(o, unittest.hasLength(2)); |
196 checkApk(o[0]); | 196 checkApk(o[0]); |
197 checkApk(o[1]); | 197 checkApk(o[1]); |
198 } | 198 } |
199 | 199 |
200 core.int buildCounterApksListResponse = 0; | 200 core.int buildCounterApksListResponse = 0; |
201 buildApksListResponse() { | 201 buildApksListResponse() { |
202 var o = new api.ApksListResponse(); | 202 var o = new api.ApksListResponse(); |
203 buildCounterApksListResponse++; | 203 buildCounterApksListResponse++; |
204 if (buildCounterApksListResponse < 3) { | 204 if (buildCounterApksListResponse < 3) { |
205 o.apks = buildUnnamed2900(); | 205 o.apks = buildUnnamed2370(); |
206 o.kind = "foo"; | 206 o.kind = "foo"; |
207 } | 207 } |
208 buildCounterApksListResponse--; | 208 buildCounterApksListResponse--; |
209 return o; | 209 return o; |
210 } | 210 } |
211 | 211 |
212 checkApksListResponse(api.ApksListResponse o) { | 212 checkApksListResponse(api.ApksListResponse o) { |
213 buildCounterApksListResponse++; | 213 buildCounterApksListResponse++; |
214 if (buildCounterApksListResponse < 3) { | 214 if (buildCounterApksListResponse < 3) { |
215 checkUnnamed2900(o.apks); | 215 checkUnnamed2370(o.apks); |
216 unittest.expect(o.kind, unittest.equals('foo')); | 216 unittest.expect(o.kind, unittest.equals('foo')); |
217 } | 217 } |
218 buildCounterApksListResponse--; | 218 buildCounterApksListResponse--; |
219 } | 219 } |
220 | 220 |
221 core.int buildCounterAppDetails = 0; | 221 core.int buildCounterAppDetails = 0; |
222 buildAppDetails() { | 222 buildAppDetails() { |
223 var o = new api.AppDetails(); | 223 var o = new api.AppDetails(); |
224 buildCounterAppDetails++; | 224 buildCounterAppDetails++; |
225 if (buildCounterAppDetails < 3) { | 225 if (buildCounterAppDetails < 3) { |
(...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
401 buildCounterEntitlement++; | 401 buildCounterEntitlement++; |
402 if (buildCounterEntitlement < 3) { | 402 if (buildCounterEntitlement < 3) { |
403 unittest.expect(o.kind, unittest.equals('foo')); | 403 unittest.expect(o.kind, unittest.equals('foo')); |
404 unittest.expect(o.productId, unittest.equals('foo')); | 404 unittest.expect(o.productId, unittest.equals('foo')); |
405 unittest.expect(o.productType, unittest.equals('foo')); | 405 unittest.expect(o.productType, unittest.equals('foo')); |
406 unittest.expect(o.token, unittest.equals('foo')); | 406 unittest.expect(o.token, unittest.equals('foo')); |
407 } | 407 } |
408 buildCounterEntitlement--; | 408 buildCounterEntitlement--; |
409 } | 409 } |
410 | 410 |
411 buildUnnamed2901() { | 411 buildUnnamed2371() { |
412 var o = new core.List<api.Entitlement>(); | 412 var o = new core.List<api.Entitlement>(); |
413 o.add(buildEntitlement()); | 413 o.add(buildEntitlement()); |
414 o.add(buildEntitlement()); | 414 o.add(buildEntitlement()); |
415 return o; | 415 return o; |
416 } | 416 } |
417 | 417 |
418 checkUnnamed2901(core.List<api.Entitlement> o) { | 418 checkUnnamed2371(core.List<api.Entitlement> o) { |
419 unittest.expect(o, unittest.hasLength(2)); | 419 unittest.expect(o, unittest.hasLength(2)); |
420 checkEntitlement(o[0]); | 420 checkEntitlement(o[0]); |
421 checkEntitlement(o[1]); | 421 checkEntitlement(o[1]); |
422 } | 422 } |
423 | 423 |
424 core.int buildCounterEntitlementsListResponse = 0; | 424 core.int buildCounterEntitlementsListResponse = 0; |
425 buildEntitlementsListResponse() { | 425 buildEntitlementsListResponse() { |
426 var o = new api.EntitlementsListResponse(); | 426 var o = new api.EntitlementsListResponse(); |
427 buildCounterEntitlementsListResponse++; | 427 buildCounterEntitlementsListResponse++; |
428 if (buildCounterEntitlementsListResponse < 3) { | 428 if (buildCounterEntitlementsListResponse < 3) { |
429 o.pageInfo = buildPageInfo(); | 429 o.pageInfo = buildPageInfo(); |
430 o.resources = buildUnnamed2901(); | 430 o.resources = buildUnnamed2371(); |
431 o.tokenPagination = buildTokenPagination(); | 431 o.tokenPagination = buildTokenPagination(); |
432 } | 432 } |
433 buildCounterEntitlementsListResponse--; | 433 buildCounterEntitlementsListResponse--; |
434 return o; | 434 return o; |
435 } | 435 } |
436 | 436 |
437 checkEntitlementsListResponse(api.EntitlementsListResponse o) { | 437 checkEntitlementsListResponse(api.EntitlementsListResponse o) { |
438 buildCounterEntitlementsListResponse++; | 438 buildCounterEntitlementsListResponse++; |
439 if (buildCounterEntitlementsListResponse < 3) { | 439 if (buildCounterEntitlementsListResponse < 3) { |
440 checkPageInfo(o.pageInfo); | 440 checkPageInfo(o.pageInfo); |
441 checkUnnamed2901(o.resources); | 441 checkUnnamed2371(o.resources); |
442 checkTokenPagination(o.tokenPagination); | 442 checkTokenPagination(o.tokenPagination); |
443 } | 443 } |
444 buildCounterEntitlementsListResponse--; | 444 buildCounterEntitlementsListResponse--; |
445 } | 445 } |
446 | 446 |
447 core.int buildCounterExpansionFile = 0; | 447 core.int buildCounterExpansionFile = 0; |
448 buildExpansionFile() { | 448 buildExpansionFile() { |
449 var o = new api.ExpansionFile(); | 449 var o = new api.ExpansionFile(); |
450 buildCounterExpansionFile++; | 450 buildCounterExpansionFile++; |
451 if (buildCounterExpansionFile < 3) { | 451 if (buildCounterExpansionFile < 3) { |
(...skipping 25 matching lines...) Expand all Loading... |
477 } | 477 } |
478 | 478 |
479 checkExpansionFilesUploadResponse(api.ExpansionFilesUploadResponse o) { | 479 checkExpansionFilesUploadResponse(api.ExpansionFilesUploadResponse o) { |
480 buildCounterExpansionFilesUploadResponse++; | 480 buildCounterExpansionFilesUploadResponse++; |
481 if (buildCounterExpansionFilesUploadResponse < 3) { | 481 if (buildCounterExpansionFilesUploadResponse < 3) { |
482 checkExpansionFile(o.expansionFile); | 482 checkExpansionFile(o.expansionFile); |
483 } | 483 } |
484 buildCounterExpansionFilesUploadResponse--; | 484 buildCounterExpansionFilesUploadResponse--; |
485 } | 485 } |
486 | 486 |
487 buildUnnamed2902() { | 487 buildUnnamed2372() { |
488 var o = new core.List<core.String>(); | 488 var o = new core.List<core.String>(); |
489 o.add("foo"); | 489 o.add("foo"); |
490 o.add("foo"); | 490 o.add("foo"); |
491 return o; | 491 return o; |
492 } | 492 } |
493 | 493 |
494 checkUnnamed2902(core.List<core.String> o) { | 494 checkUnnamed2372(core.List<core.String> o) { |
495 unittest.expect(o, unittest.hasLength(2)); | 495 unittest.expect(o, unittest.hasLength(2)); |
496 unittest.expect(o[0], unittest.equals('foo')); | 496 unittest.expect(o[0], unittest.equals('foo')); |
497 unittest.expect(o[1], unittest.equals('foo')); | 497 unittest.expect(o[1], unittest.equals('foo')); |
498 } | 498 } |
499 | 499 |
500 buildUnnamed2903() { | 500 buildUnnamed2373() { |
501 var o = new core.List<core.String>(); | 501 var o = new core.List<core.String>(); |
502 o.add("foo"); | 502 o.add("foo"); |
503 o.add("foo"); | 503 o.add("foo"); |
504 return o; | 504 return o; |
505 } | 505 } |
506 | 506 |
507 checkUnnamed2903(core.List<core.String> o) { | 507 checkUnnamed2373(core.List<core.String> o) { |
508 unittest.expect(o, unittest.hasLength(2)); | 508 unittest.expect(o, unittest.hasLength(2)); |
509 unittest.expect(o[0], unittest.equals('foo')); | 509 unittest.expect(o[0], unittest.equals('foo')); |
510 unittest.expect(o[1], unittest.equals('foo')); | 510 unittest.expect(o[1], unittest.equals('foo')); |
511 } | 511 } |
512 | 512 |
513 buildUnnamed2904() { | 513 buildUnnamed2374() { |
514 var o = new core.List<core.String>(); | 514 var o = new core.List<core.String>(); |
515 o.add("foo"); | 515 o.add("foo"); |
516 o.add("foo"); | 516 o.add("foo"); |
517 return o; | 517 return o; |
518 } | 518 } |
519 | 519 |
520 checkUnnamed2904(core.List<core.String> o) { | 520 checkUnnamed2374(core.List<core.String> o) { |
521 unittest.expect(o, unittest.hasLength(2)); | 521 unittest.expect(o, unittest.hasLength(2)); |
522 unittest.expect(o[0], unittest.equals('foo')); | 522 unittest.expect(o[0], unittest.equals('foo')); |
523 unittest.expect(o[1], unittest.equals('foo')); | 523 unittest.expect(o[1], unittest.equals('foo')); |
524 } | 524 } |
525 | 525 |
526 buildUnnamed2905() { | 526 buildUnnamed2375() { |
527 var o = new core.List<api.ExternallyHostedApkUsesPermission>(); | 527 var o = new core.List<api.ExternallyHostedApkUsesPermission>(); |
528 o.add(buildExternallyHostedApkUsesPermission()); | 528 o.add(buildExternallyHostedApkUsesPermission()); |
529 o.add(buildExternallyHostedApkUsesPermission()); | 529 o.add(buildExternallyHostedApkUsesPermission()); |
530 return o; | 530 return o; |
531 } | 531 } |
532 | 532 |
533 checkUnnamed2905(core.List<api.ExternallyHostedApkUsesPermission> o) { | 533 checkUnnamed2375(core.List<api.ExternallyHostedApkUsesPermission> o) { |
534 unittest.expect(o, unittest.hasLength(2)); | 534 unittest.expect(o, unittest.hasLength(2)); |
535 checkExternallyHostedApkUsesPermission(o[0]); | 535 checkExternallyHostedApkUsesPermission(o[0]); |
536 checkExternallyHostedApkUsesPermission(o[1]); | 536 checkExternallyHostedApkUsesPermission(o[1]); |
537 } | 537 } |
538 | 538 |
539 core.int buildCounterExternallyHostedApk = 0; | 539 core.int buildCounterExternallyHostedApk = 0; |
540 buildExternallyHostedApk() { | 540 buildExternallyHostedApk() { |
541 var o = new api.ExternallyHostedApk(); | 541 var o = new api.ExternallyHostedApk(); |
542 buildCounterExternallyHostedApk++; | 542 buildCounterExternallyHostedApk++; |
543 if (buildCounterExternallyHostedApk < 3) { | 543 if (buildCounterExternallyHostedApk < 3) { |
544 o.applicationLabel = "foo"; | 544 o.applicationLabel = "foo"; |
545 o.certificateBase64s = buildUnnamed2902(); | 545 o.certificateBase64s = buildUnnamed2372(); |
546 o.externallyHostedUrl = "foo"; | 546 o.externallyHostedUrl = "foo"; |
547 o.fileSha1Base64 = "foo"; | 547 o.fileSha1Base64 = "foo"; |
548 o.fileSha256Base64 = "foo"; | 548 o.fileSha256Base64 = "foo"; |
549 o.fileSize = "foo"; | 549 o.fileSize = "foo"; |
550 o.iconBase64 = "foo"; | 550 o.iconBase64 = "foo"; |
551 o.maximumSdk = 42; | 551 o.maximumSdk = 42; |
552 o.minimumSdk = 42; | 552 o.minimumSdk = 42; |
553 o.nativeCodes = buildUnnamed2903(); | 553 o.nativeCodes = buildUnnamed2373(); |
554 o.packageName = "foo"; | 554 o.packageName = "foo"; |
555 o.usesFeatures = buildUnnamed2904(); | 555 o.usesFeatures = buildUnnamed2374(); |
556 o.usesPermissions = buildUnnamed2905(); | 556 o.usesPermissions = buildUnnamed2375(); |
557 o.versionCode = 42; | 557 o.versionCode = 42; |
558 o.versionName = "foo"; | 558 o.versionName = "foo"; |
559 } | 559 } |
560 buildCounterExternallyHostedApk--; | 560 buildCounterExternallyHostedApk--; |
561 return o; | 561 return o; |
562 } | 562 } |
563 | 563 |
564 checkExternallyHostedApk(api.ExternallyHostedApk o) { | 564 checkExternallyHostedApk(api.ExternallyHostedApk o) { |
565 buildCounterExternallyHostedApk++; | 565 buildCounterExternallyHostedApk++; |
566 if (buildCounterExternallyHostedApk < 3) { | 566 if (buildCounterExternallyHostedApk < 3) { |
567 unittest.expect(o.applicationLabel, unittest.equals('foo')); | 567 unittest.expect(o.applicationLabel, unittest.equals('foo')); |
568 checkUnnamed2902(o.certificateBase64s); | 568 checkUnnamed2372(o.certificateBase64s); |
569 unittest.expect(o.externallyHostedUrl, unittest.equals('foo')); | 569 unittest.expect(o.externallyHostedUrl, unittest.equals('foo')); |
570 unittest.expect(o.fileSha1Base64, unittest.equals('foo')); | 570 unittest.expect(o.fileSha1Base64, unittest.equals('foo')); |
571 unittest.expect(o.fileSha256Base64, unittest.equals('foo')); | 571 unittest.expect(o.fileSha256Base64, unittest.equals('foo')); |
572 unittest.expect(o.fileSize, unittest.equals('foo')); | 572 unittest.expect(o.fileSize, unittest.equals('foo')); |
573 unittest.expect(o.iconBase64, unittest.equals('foo')); | 573 unittest.expect(o.iconBase64, unittest.equals('foo')); |
574 unittest.expect(o.maximumSdk, unittest.equals(42)); | 574 unittest.expect(o.maximumSdk, unittest.equals(42)); |
575 unittest.expect(o.minimumSdk, unittest.equals(42)); | 575 unittest.expect(o.minimumSdk, unittest.equals(42)); |
576 checkUnnamed2903(o.nativeCodes); | 576 checkUnnamed2373(o.nativeCodes); |
577 unittest.expect(o.packageName, unittest.equals('foo')); | 577 unittest.expect(o.packageName, unittest.equals('foo')); |
578 checkUnnamed2904(o.usesFeatures); | 578 checkUnnamed2374(o.usesFeatures); |
579 checkUnnamed2905(o.usesPermissions); | 579 checkUnnamed2375(o.usesPermissions); |
580 unittest.expect(o.versionCode, unittest.equals(42)); | 580 unittest.expect(o.versionCode, unittest.equals(42)); |
581 unittest.expect(o.versionName, unittest.equals('foo')); | 581 unittest.expect(o.versionName, unittest.equals('foo')); |
582 } | 582 } |
583 buildCounterExternallyHostedApk--; | 583 buildCounterExternallyHostedApk--; |
584 } | 584 } |
585 | 585 |
586 core.int buildCounterExternallyHostedApkUsesPermission = 0; | 586 core.int buildCounterExternallyHostedApkUsesPermission = 0; |
587 buildExternallyHostedApkUsesPermission() { | 587 buildExternallyHostedApkUsesPermission() { |
588 var o = new api.ExternallyHostedApkUsesPermission(); | 588 var o = new api.ExternallyHostedApkUsesPermission(); |
589 buildCounterExternallyHostedApkUsesPermission++; | 589 buildCounterExternallyHostedApkUsesPermission++; |
(...skipping 30 matching lines...) Expand all Loading... |
620 checkImage(api.Image o) { | 620 checkImage(api.Image o) { |
621 buildCounterImage++; | 621 buildCounterImage++; |
622 if (buildCounterImage < 3) { | 622 if (buildCounterImage < 3) { |
623 unittest.expect(o.id, unittest.equals('foo')); | 623 unittest.expect(o.id, unittest.equals('foo')); |
624 unittest.expect(o.sha1, unittest.equals('foo')); | 624 unittest.expect(o.sha1, unittest.equals('foo')); |
625 unittest.expect(o.url, unittest.equals('foo')); | 625 unittest.expect(o.url, unittest.equals('foo')); |
626 } | 626 } |
627 buildCounterImage--; | 627 buildCounterImage--; |
628 } | 628 } |
629 | 629 |
630 buildUnnamed2906() { | 630 buildUnnamed2376() { |
631 var o = new core.List<api.Image>(); | 631 var o = new core.List<api.Image>(); |
632 o.add(buildImage()); | 632 o.add(buildImage()); |
633 o.add(buildImage()); | 633 o.add(buildImage()); |
634 return o; | 634 return o; |
635 } | 635 } |
636 | 636 |
637 checkUnnamed2906(core.List<api.Image> o) { | 637 checkUnnamed2376(core.List<api.Image> o) { |
638 unittest.expect(o, unittest.hasLength(2)); | 638 unittest.expect(o, unittest.hasLength(2)); |
639 checkImage(o[0]); | 639 checkImage(o[0]); |
640 checkImage(o[1]); | 640 checkImage(o[1]); |
641 } | 641 } |
642 | 642 |
643 core.int buildCounterImagesDeleteAllResponse = 0; | 643 core.int buildCounterImagesDeleteAllResponse = 0; |
644 buildImagesDeleteAllResponse() { | 644 buildImagesDeleteAllResponse() { |
645 var o = new api.ImagesDeleteAllResponse(); | 645 var o = new api.ImagesDeleteAllResponse(); |
646 buildCounterImagesDeleteAllResponse++; | 646 buildCounterImagesDeleteAllResponse++; |
647 if (buildCounterImagesDeleteAllResponse < 3) { | 647 if (buildCounterImagesDeleteAllResponse < 3) { |
648 o.deleted = buildUnnamed2906(); | 648 o.deleted = buildUnnamed2376(); |
649 } | 649 } |
650 buildCounterImagesDeleteAllResponse--; | 650 buildCounterImagesDeleteAllResponse--; |
651 return o; | 651 return o; |
652 } | 652 } |
653 | 653 |
654 checkImagesDeleteAllResponse(api.ImagesDeleteAllResponse o) { | 654 checkImagesDeleteAllResponse(api.ImagesDeleteAllResponse o) { |
655 buildCounterImagesDeleteAllResponse++; | 655 buildCounterImagesDeleteAllResponse++; |
656 if (buildCounterImagesDeleteAllResponse < 3) { | 656 if (buildCounterImagesDeleteAllResponse < 3) { |
657 checkUnnamed2906(o.deleted); | 657 checkUnnamed2376(o.deleted); |
658 } | 658 } |
659 buildCounterImagesDeleteAllResponse--; | 659 buildCounterImagesDeleteAllResponse--; |
660 } | 660 } |
661 | 661 |
662 buildUnnamed2907() { | 662 buildUnnamed2377() { |
663 var o = new core.List<api.Image>(); | 663 var o = new core.List<api.Image>(); |
664 o.add(buildImage()); | 664 o.add(buildImage()); |
665 o.add(buildImage()); | 665 o.add(buildImage()); |
666 return o; | 666 return o; |
667 } | 667 } |
668 | 668 |
669 checkUnnamed2907(core.List<api.Image> o) { | 669 checkUnnamed2377(core.List<api.Image> o) { |
670 unittest.expect(o, unittest.hasLength(2)); | 670 unittest.expect(o, unittest.hasLength(2)); |
671 checkImage(o[0]); | 671 checkImage(o[0]); |
672 checkImage(o[1]); | 672 checkImage(o[1]); |
673 } | 673 } |
674 | 674 |
675 core.int buildCounterImagesListResponse = 0; | 675 core.int buildCounterImagesListResponse = 0; |
676 buildImagesListResponse() { | 676 buildImagesListResponse() { |
677 var o = new api.ImagesListResponse(); | 677 var o = new api.ImagesListResponse(); |
678 buildCounterImagesListResponse++; | 678 buildCounterImagesListResponse++; |
679 if (buildCounterImagesListResponse < 3) { | 679 if (buildCounterImagesListResponse < 3) { |
680 o.images = buildUnnamed2907(); | 680 o.images = buildUnnamed2377(); |
681 } | 681 } |
682 buildCounterImagesListResponse--; | 682 buildCounterImagesListResponse--; |
683 return o; | 683 return o; |
684 } | 684 } |
685 | 685 |
686 checkImagesListResponse(api.ImagesListResponse o) { | 686 checkImagesListResponse(api.ImagesListResponse o) { |
687 buildCounterImagesListResponse++; | 687 buildCounterImagesListResponse++; |
688 if (buildCounterImagesListResponse < 3) { | 688 if (buildCounterImagesListResponse < 3) { |
689 checkUnnamed2907(o.images); | 689 checkUnnamed2377(o.images); |
690 } | 690 } |
691 buildCounterImagesListResponse--; | 691 buildCounterImagesListResponse--; |
692 } | 692 } |
693 | 693 |
694 core.int buildCounterImagesUploadResponse = 0; | 694 core.int buildCounterImagesUploadResponse = 0; |
695 buildImagesUploadResponse() { | 695 buildImagesUploadResponse() { |
696 var o = new api.ImagesUploadResponse(); | 696 var o = new api.ImagesUploadResponse(); |
697 buildCounterImagesUploadResponse++; | 697 buildCounterImagesUploadResponse++; |
698 if (buildCounterImagesUploadResponse < 3) { | 698 if (buildCounterImagesUploadResponse < 3) { |
699 o.image = buildImage(); | 699 o.image = buildImage(); |
700 } | 700 } |
701 buildCounterImagesUploadResponse--; | 701 buildCounterImagesUploadResponse--; |
702 return o; | 702 return o; |
703 } | 703 } |
704 | 704 |
705 checkImagesUploadResponse(api.ImagesUploadResponse o) { | 705 checkImagesUploadResponse(api.ImagesUploadResponse o) { |
706 buildCounterImagesUploadResponse++; | 706 buildCounterImagesUploadResponse++; |
707 if (buildCounterImagesUploadResponse < 3) { | 707 if (buildCounterImagesUploadResponse < 3) { |
708 checkImage(o.image); | 708 checkImage(o.image); |
709 } | 709 } |
710 buildCounterImagesUploadResponse--; | 710 buildCounterImagesUploadResponse--; |
711 } | 711 } |
712 | 712 |
713 buildUnnamed2908() { | 713 buildUnnamed2378() { |
714 var o = new core.Map<core.String, api.InAppProductListing>(); | 714 var o = new core.Map<core.String, api.InAppProductListing>(); |
715 o["x"] = buildInAppProductListing(); | 715 o["x"] = buildInAppProductListing(); |
716 o["y"] = buildInAppProductListing(); | 716 o["y"] = buildInAppProductListing(); |
717 return o; | 717 return o; |
718 } | 718 } |
719 | 719 |
720 checkUnnamed2908(core.Map<core.String, api.InAppProductListing> o) { | 720 checkUnnamed2378(core.Map<core.String, api.InAppProductListing> o) { |
721 unittest.expect(o, unittest.hasLength(2)); | 721 unittest.expect(o, unittest.hasLength(2)); |
722 checkInAppProductListing(o["x"]); | 722 checkInAppProductListing(o["x"]); |
723 checkInAppProductListing(o["y"]); | 723 checkInAppProductListing(o["y"]); |
724 } | 724 } |
725 | 725 |
726 buildUnnamed2909() { | 726 buildUnnamed2379() { |
727 var o = new core.Map<core.String, api.Price>(); | 727 var o = new core.Map<core.String, api.Price>(); |
728 o["x"] = buildPrice(); | 728 o["x"] = buildPrice(); |
729 o["y"] = buildPrice(); | 729 o["y"] = buildPrice(); |
730 return o; | 730 return o; |
731 } | 731 } |
732 | 732 |
733 checkUnnamed2909(core.Map<core.String, api.Price> o) { | 733 checkUnnamed2379(core.Map<core.String, api.Price> o) { |
734 unittest.expect(o, unittest.hasLength(2)); | 734 unittest.expect(o, unittest.hasLength(2)); |
735 checkPrice(o["x"]); | 735 checkPrice(o["x"]); |
736 checkPrice(o["y"]); | 736 checkPrice(o["y"]); |
737 } | 737 } |
738 | 738 |
739 core.int buildCounterInAppProduct = 0; | 739 core.int buildCounterInAppProduct = 0; |
740 buildInAppProduct() { | 740 buildInAppProduct() { |
741 var o = new api.InAppProduct(); | 741 var o = new api.InAppProduct(); |
742 buildCounterInAppProduct++; | 742 buildCounterInAppProduct++; |
743 if (buildCounterInAppProduct < 3) { | 743 if (buildCounterInAppProduct < 3) { |
744 o.defaultLanguage = "foo"; | 744 o.defaultLanguage = "foo"; |
745 o.defaultPrice = buildPrice(); | 745 o.defaultPrice = buildPrice(); |
746 o.listings = buildUnnamed2908(); | 746 o.listings = buildUnnamed2378(); |
747 o.packageName = "foo"; | 747 o.packageName = "foo"; |
748 o.prices = buildUnnamed2909(); | 748 o.prices = buildUnnamed2379(); |
749 o.purchaseType = "foo"; | 749 o.purchaseType = "foo"; |
750 o.season = buildSeason(); | 750 o.season = buildSeason(); |
751 o.sku = "foo"; | 751 o.sku = "foo"; |
752 o.status = "foo"; | 752 o.status = "foo"; |
753 o.subscriptionPeriod = "foo"; | 753 o.subscriptionPeriod = "foo"; |
754 o.trialPeriod = "foo"; | 754 o.trialPeriod = "foo"; |
755 } | 755 } |
756 buildCounterInAppProduct--; | 756 buildCounterInAppProduct--; |
757 return o; | 757 return o; |
758 } | 758 } |
759 | 759 |
760 checkInAppProduct(api.InAppProduct o) { | 760 checkInAppProduct(api.InAppProduct o) { |
761 buildCounterInAppProduct++; | 761 buildCounterInAppProduct++; |
762 if (buildCounterInAppProduct < 3) { | 762 if (buildCounterInAppProduct < 3) { |
763 unittest.expect(o.defaultLanguage, unittest.equals('foo')); | 763 unittest.expect(o.defaultLanguage, unittest.equals('foo')); |
764 checkPrice(o.defaultPrice); | 764 checkPrice(o.defaultPrice); |
765 checkUnnamed2908(o.listings); | 765 checkUnnamed2378(o.listings); |
766 unittest.expect(o.packageName, unittest.equals('foo')); | 766 unittest.expect(o.packageName, unittest.equals('foo')); |
767 checkUnnamed2909(o.prices); | 767 checkUnnamed2379(o.prices); |
768 unittest.expect(o.purchaseType, unittest.equals('foo')); | 768 unittest.expect(o.purchaseType, unittest.equals('foo')); |
769 checkSeason(o.season); | 769 checkSeason(o.season); |
770 unittest.expect(o.sku, unittest.equals('foo')); | 770 unittest.expect(o.sku, unittest.equals('foo')); |
771 unittest.expect(o.status, unittest.equals('foo')); | 771 unittest.expect(o.status, unittest.equals('foo')); |
772 unittest.expect(o.subscriptionPeriod, unittest.equals('foo')); | 772 unittest.expect(o.subscriptionPeriod, unittest.equals('foo')); |
773 unittest.expect(o.trialPeriod, unittest.equals('foo')); | 773 unittest.expect(o.trialPeriod, unittest.equals('foo')); |
774 } | 774 } |
775 buildCounterInAppProduct--; | 775 buildCounterInAppProduct--; |
776 } | 776 } |
777 | 777 |
(...skipping 11 matching lines...) Expand all Loading... |
789 | 789 |
790 checkInAppProductListing(api.InAppProductListing o) { | 790 checkInAppProductListing(api.InAppProductListing o) { |
791 buildCounterInAppProductListing++; | 791 buildCounterInAppProductListing++; |
792 if (buildCounterInAppProductListing < 3) { | 792 if (buildCounterInAppProductListing < 3) { |
793 unittest.expect(o.description, unittest.equals('foo')); | 793 unittest.expect(o.description, unittest.equals('foo')); |
794 unittest.expect(o.title, unittest.equals('foo')); | 794 unittest.expect(o.title, unittest.equals('foo')); |
795 } | 795 } |
796 buildCounterInAppProductListing--; | 796 buildCounterInAppProductListing--; |
797 } | 797 } |
798 | 798 |
799 buildUnnamed2910() { | 799 buildUnnamed2380() { |
800 var o = new core.List<api.InappproductsBatchRequestEntry>(); | 800 var o = new core.List<api.InappproductsBatchRequestEntry>(); |
801 o.add(buildInappproductsBatchRequestEntry()); | 801 o.add(buildInappproductsBatchRequestEntry()); |
802 o.add(buildInappproductsBatchRequestEntry()); | 802 o.add(buildInappproductsBatchRequestEntry()); |
803 return o; | 803 return o; |
804 } | 804 } |
805 | 805 |
806 checkUnnamed2910(core.List<api.InappproductsBatchRequestEntry> o) { | 806 checkUnnamed2380(core.List<api.InappproductsBatchRequestEntry> o) { |
807 unittest.expect(o, unittest.hasLength(2)); | 807 unittest.expect(o, unittest.hasLength(2)); |
808 checkInappproductsBatchRequestEntry(o[0]); | 808 checkInappproductsBatchRequestEntry(o[0]); |
809 checkInappproductsBatchRequestEntry(o[1]); | 809 checkInappproductsBatchRequestEntry(o[1]); |
810 } | 810 } |
811 | 811 |
812 core.int buildCounterInappproductsBatchRequest = 0; | 812 core.int buildCounterInappproductsBatchRequest = 0; |
813 buildInappproductsBatchRequest() { | 813 buildInappproductsBatchRequest() { |
814 var o = new api.InappproductsBatchRequest(); | 814 var o = new api.InappproductsBatchRequest(); |
815 buildCounterInappproductsBatchRequest++; | 815 buildCounterInappproductsBatchRequest++; |
816 if (buildCounterInappproductsBatchRequest < 3) { | 816 if (buildCounterInappproductsBatchRequest < 3) { |
817 o.entrys = buildUnnamed2910(); | 817 o.entrys = buildUnnamed2380(); |
818 } | 818 } |
819 buildCounterInappproductsBatchRequest--; | 819 buildCounterInappproductsBatchRequest--; |
820 return o; | 820 return o; |
821 } | 821 } |
822 | 822 |
823 checkInappproductsBatchRequest(api.InappproductsBatchRequest o) { | 823 checkInappproductsBatchRequest(api.InappproductsBatchRequest o) { |
824 buildCounterInappproductsBatchRequest++; | 824 buildCounterInappproductsBatchRequest++; |
825 if (buildCounterInappproductsBatchRequest < 3) { | 825 if (buildCounterInappproductsBatchRequest < 3) { |
826 checkUnnamed2910(o.entrys); | 826 checkUnnamed2380(o.entrys); |
827 } | 827 } |
828 buildCounterInappproductsBatchRequest--; | 828 buildCounterInappproductsBatchRequest--; |
829 } | 829 } |
830 | 830 |
831 core.int buildCounterInappproductsBatchRequestEntry = 0; | 831 core.int buildCounterInappproductsBatchRequestEntry = 0; |
832 buildInappproductsBatchRequestEntry() { | 832 buildInappproductsBatchRequestEntry() { |
833 var o = new api.InappproductsBatchRequestEntry(); | 833 var o = new api.InappproductsBatchRequestEntry(); |
834 buildCounterInappproductsBatchRequestEntry++; | 834 buildCounterInappproductsBatchRequestEntry++; |
835 if (buildCounterInappproductsBatchRequestEntry < 3) { | 835 if (buildCounterInappproductsBatchRequestEntry < 3) { |
836 o.batchId = 42; | 836 o.batchId = 42; |
837 o.inappproductsinsertrequest = buildInappproductsInsertRequest(); | 837 o.inappproductsinsertrequest = buildInappproductsInsertRequest(); |
838 o.inappproductsupdaterequest = buildInappproductsUpdateRequest(); | 838 o.inappproductsupdaterequest = buildInappproductsUpdateRequest(); |
839 o.methodName = "foo"; | 839 o.methodName = "foo"; |
840 } | 840 } |
841 buildCounterInappproductsBatchRequestEntry--; | 841 buildCounterInappproductsBatchRequestEntry--; |
842 return o; | 842 return o; |
843 } | 843 } |
844 | 844 |
845 checkInappproductsBatchRequestEntry(api.InappproductsBatchRequestEntry o) { | 845 checkInappproductsBatchRequestEntry(api.InappproductsBatchRequestEntry o) { |
846 buildCounterInappproductsBatchRequestEntry++; | 846 buildCounterInappproductsBatchRequestEntry++; |
847 if (buildCounterInappproductsBatchRequestEntry < 3) { | 847 if (buildCounterInappproductsBatchRequestEntry < 3) { |
848 unittest.expect(o.batchId, unittest.equals(42)); | 848 unittest.expect(o.batchId, unittest.equals(42)); |
849 checkInappproductsInsertRequest(o.inappproductsinsertrequest); | 849 checkInappproductsInsertRequest(o.inappproductsinsertrequest); |
850 checkInappproductsUpdateRequest(o.inappproductsupdaterequest); | 850 checkInappproductsUpdateRequest(o.inappproductsupdaterequest); |
851 unittest.expect(o.methodName, unittest.equals('foo')); | 851 unittest.expect(o.methodName, unittest.equals('foo')); |
852 } | 852 } |
853 buildCounterInappproductsBatchRequestEntry--; | 853 buildCounterInappproductsBatchRequestEntry--; |
854 } | 854 } |
855 | 855 |
856 buildUnnamed2911() { | 856 buildUnnamed2381() { |
857 var o = new core.List<api.InappproductsBatchResponseEntry>(); | 857 var o = new core.List<api.InappproductsBatchResponseEntry>(); |
858 o.add(buildInappproductsBatchResponseEntry()); | 858 o.add(buildInappproductsBatchResponseEntry()); |
859 o.add(buildInappproductsBatchResponseEntry()); | 859 o.add(buildInappproductsBatchResponseEntry()); |
860 return o; | 860 return o; |
861 } | 861 } |
862 | 862 |
863 checkUnnamed2911(core.List<api.InappproductsBatchResponseEntry> o) { | 863 checkUnnamed2381(core.List<api.InappproductsBatchResponseEntry> o) { |
864 unittest.expect(o, unittest.hasLength(2)); | 864 unittest.expect(o, unittest.hasLength(2)); |
865 checkInappproductsBatchResponseEntry(o[0]); | 865 checkInappproductsBatchResponseEntry(o[0]); |
866 checkInappproductsBatchResponseEntry(o[1]); | 866 checkInappproductsBatchResponseEntry(o[1]); |
867 } | 867 } |
868 | 868 |
869 core.int buildCounterInappproductsBatchResponse = 0; | 869 core.int buildCounterInappproductsBatchResponse = 0; |
870 buildInappproductsBatchResponse() { | 870 buildInappproductsBatchResponse() { |
871 var o = new api.InappproductsBatchResponse(); | 871 var o = new api.InappproductsBatchResponse(); |
872 buildCounterInappproductsBatchResponse++; | 872 buildCounterInappproductsBatchResponse++; |
873 if (buildCounterInappproductsBatchResponse < 3) { | 873 if (buildCounterInappproductsBatchResponse < 3) { |
874 o.entrys = buildUnnamed2911(); | 874 o.entrys = buildUnnamed2381(); |
875 o.kind = "foo"; | 875 o.kind = "foo"; |
876 } | 876 } |
877 buildCounterInappproductsBatchResponse--; | 877 buildCounterInappproductsBatchResponse--; |
878 return o; | 878 return o; |
879 } | 879 } |
880 | 880 |
881 checkInappproductsBatchResponse(api.InappproductsBatchResponse o) { | 881 checkInappproductsBatchResponse(api.InappproductsBatchResponse o) { |
882 buildCounterInappproductsBatchResponse++; | 882 buildCounterInappproductsBatchResponse++; |
883 if (buildCounterInappproductsBatchResponse < 3) { | 883 if (buildCounterInappproductsBatchResponse < 3) { |
884 checkUnnamed2911(o.entrys); | 884 checkUnnamed2381(o.entrys); |
885 unittest.expect(o.kind, unittest.equals('foo')); | 885 unittest.expect(o.kind, unittest.equals('foo')); |
886 } | 886 } |
887 buildCounterInappproductsBatchResponse--; | 887 buildCounterInappproductsBatchResponse--; |
888 } | 888 } |
889 | 889 |
890 core.int buildCounterInappproductsBatchResponseEntry = 0; | 890 core.int buildCounterInappproductsBatchResponseEntry = 0; |
891 buildInappproductsBatchResponseEntry() { | 891 buildInappproductsBatchResponseEntry() { |
892 var o = new api.InappproductsBatchResponseEntry(); | 892 var o = new api.InappproductsBatchResponseEntry(); |
893 buildCounterInappproductsBatchResponseEntry++; | 893 buildCounterInappproductsBatchResponseEntry++; |
894 if (buildCounterInappproductsBatchResponseEntry < 3) { | 894 if (buildCounterInappproductsBatchResponseEntry < 3) { |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
941 } | 941 } |
942 | 942 |
943 checkInappproductsInsertResponse(api.InappproductsInsertResponse o) { | 943 checkInappproductsInsertResponse(api.InappproductsInsertResponse o) { |
944 buildCounterInappproductsInsertResponse++; | 944 buildCounterInappproductsInsertResponse++; |
945 if (buildCounterInappproductsInsertResponse < 3) { | 945 if (buildCounterInappproductsInsertResponse < 3) { |
946 checkInAppProduct(o.inappproduct); | 946 checkInAppProduct(o.inappproduct); |
947 } | 947 } |
948 buildCounterInappproductsInsertResponse--; | 948 buildCounterInappproductsInsertResponse--; |
949 } | 949 } |
950 | 950 |
951 buildUnnamed2912() { | 951 buildUnnamed2382() { |
952 var o = new core.List<api.InAppProduct>(); | 952 var o = new core.List<api.InAppProduct>(); |
953 o.add(buildInAppProduct()); | 953 o.add(buildInAppProduct()); |
954 o.add(buildInAppProduct()); | 954 o.add(buildInAppProduct()); |
955 return o; | 955 return o; |
956 } | 956 } |
957 | 957 |
958 checkUnnamed2912(core.List<api.InAppProduct> o) { | 958 checkUnnamed2382(core.List<api.InAppProduct> o) { |
959 unittest.expect(o, unittest.hasLength(2)); | 959 unittest.expect(o, unittest.hasLength(2)); |
960 checkInAppProduct(o[0]); | 960 checkInAppProduct(o[0]); |
961 checkInAppProduct(o[1]); | 961 checkInAppProduct(o[1]); |
962 } | 962 } |
963 | 963 |
964 core.int buildCounterInappproductsListResponse = 0; | 964 core.int buildCounterInappproductsListResponse = 0; |
965 buildInappproductsListResponse() { | 965 buildInappproductsListResponse() { |
966 var o = new api.InappproductsListResponse(); | 966 var o = new api.InappproductsListResponse(); |
967 buildCounterInappproductsListResponse++; | 967 buildCounterInappproductsListResponse++; |
968 if (buildCounterInappproductsListResponse < 3) { | 968 if (buildCounterInappproductsListResponse < 3) { |
969 o.inappproduct = buildUnnamed2912(); | 969 o.inappproduct = buildUnnamed2382(); |
970 o.kind = "foo"; | 970 o.kind = "foo"; |
971 o.pageInfo = buildPageInfo(); | 971 o.pageInfo = buildPageInfo(); |
972 o.tokenPagination = buildTokenPagination(); | 972 o.tokenPagination = buildTokenPagination(); |
973 } | 973 } |
974 buildCounterInappproductsListResponse--; | 974 buildCounterInappproductsListResponse--; |
975 return o; | 975 return o; |
976 } | 976 } |
977 | 977 |
978 checkInappproductsListResponse(api.InappproductsListResponse o) { | 978 checkInappproductsListResponse(api.InappproductsListResponse o) { |
979 buildCounterInappproductsListResponse++; | 979 buildCounterInappproductsListResponse++; |
980 if (buildCounterInappproductsListResponse < 3) { | 980 if (buildCounterInappproductsListResponse < 3) { |
981 checkUnnamed2912(o.inappproduct); | 981 checkUnnamed2382(o.inappproduct); |
982 unittest.expect(o.kind, unittest.equals('foo')); | 982 unittest.expect(o.kind, unittest.equals('foo')); |
983 checkPageInfo(o.pageInfo); | 983 checkPageInfo(o.pageInfo); |
984 checkTokenPagination(o.tokenPagination); | 984 checkTokenPagination(o.tokenPagination); |
985 } | 985 } |
986 buildCounterInappproductsListResponse--; | 986 buildCounterInappproductsListResponse--; |
987 } | 987 } |
988 | 988 |
989 core.int buildCounterInappproductsUpdateRequest = 0; | 989 core.int buildCounterInappproductsUpdateRequest = 0; |
990 buildInappproductsUpdateRequest() { | 990 buildInappproductsUpdateRequest() { |
991 var o = new api.InappproductsUpdateRequest(); | 991 var o = new api.InappproductsUpdateRequest(); |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1044 if (buildCounterListing < 3) { | 1044 if (buildCounterListing < 3) { |
1045 unittest.expect(o.fullDescription, unittest.equals('foo')); | 1045 unittest.expect(o.fullDescription, unittest.equals('foo')); |
1046 unittest.expect(o.language, unittest.equals('foo')); | 1046 unittest.expect(o.language, unittest.equals('foo')); |
1047 unittest.expect(o.shortDescription, unittest.equals('foo')); | 1047 unittest.expect(o.shortDescription, unittest.equals('foo')); |
1048 unittest.expect(o.title, unittest.equals('foo')); | 1048 unittest.expect(o.title, unittest.equals('foo')); |
1049 unittest.expect(o.video, unittest.equals('foo')); | 1049 unittest.expect(o.video, unittest.equals('foo')); |
1050 } | 1050 } |
1051 buildCounterListing--; | 1051 buildCounterListing--; |
1052 } | 1052 } |
1053 | 1053 |
1054 buildUnnamed2913() { | 1054 buildUnnamed2383() { |
1055 var o = new core.List<api.Listing>(); | 1055 var o = new core.List<api.Listing>(); |
1056 o.add(buildListing()); | 1056 o.add(buildListing()); |
1057 o.add(buildListing()); | 1057 o.add(buildListing()); |
1058 return o; | 1058 return o; |
1059 } | 1059 } |
1060 | 1060 |
1061 checkUnnamed2913(core.List<api.Listing> o) { | 1061 checkUnnamed2383(core.List<api.Listing> o) { |
1062 unittest.expect(o, unittest.hasLength(2)); | 1062 unittest.expect(o, unittest.hasLength(2)); |
1063 checkListing(o[0]); | 1063 checkListing(o[0]); |
1064 checkListing(o[1]); | 1064 checkListing(o[1]); |
1065 } | 1065 } |
1066 | 1066 |
1067 core.int buildCounterListingsListResponse = 0; | 1067 core.int buildCounterListingsListResponse = 0; |
1068 buildListingsListResponse() { | 1068 buildListingsListResponse() { |
1069 var o = new api.ListingsListResponse(); | 1069 var o = new api.ListingsListResponse(); |
1070 buildCounterListingsListResponse++; | 1070 buildCounterListingsListResponse++; |
1071 if (buildCounterListingsListResponse < 3) { | 1071 if (buildCounterListingsListResponse < 3) { |
1072 o.kind = "foo"; | 1072 o.kind = "foo"; |
1073 o.listings = buildUnnamed2913(); | 1073 o.listings = buildUnnamed2383(); |
1074 } | 1074 } |
1075 buildCounterListingsListResponse--; | 1075 buildCounterListingsListResponse--; |
1076 return o; | 1076 return o; |
1077 } | 1077 } |
1078 | 1078 |
1079 checkListingsListResponse(api.ListingsListResponse o) { | 1079 checkListingsListResponse(api.ListingsListResponse o) { |
1080 buildCounterListingsListResponse++; | 1080 buildCounterListingsListResponse++; |
1081 if (buildCounterListingsListResponse < 3) { | 1081 if (buildCounterListingsListResponse < 3) { |
1082 unittest.expect(o.kind, unittest.equals('foo')); | 1082 unittest.expect(o.kind, unittest.equals('foo')); |
1083 checkUnnamed2913(o.listings); | 1083 checkUnnamed2383(o.listings); |
1084 } | 1084 } |
1085 buildCounterListingsListResponse--; | 1085 buildCounterListingsListResponse--; |
1086 } | 1086 } |
1087 | 1087 |
1088 core.int buildCounterMonthDay = 0; | 1088 core.int buildCounterMonthDay = 0; |
1089 buildMonthDay() { | 1089 buildMonthDay() { |
1090 var o = new api.MonthDay(); | 1090 var o = new api.MonthDay(); |
1091 buildCounterMonthDay++; | 1091 buildCounterMonthDay++; |
1092 if (buildCounterMonthDay < 3) { | 1092 if (buildCounterMonthDay < 3) { |
1093 o.day = 42; | 1093 o.day = 42; |
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1191 | 1191 |
1192 checkProrate(api.Prorate o) { | 1192 checkProrate(api.Prorate o) { |
1193 buildCounterProrate++; | 1193 buildCounterProrate++; |
1194 if (buildCounterProrate < 3) { | 1194 if (buildCounterProrate < 3) { |
1195 checkPrice(o.defaultPrice); | 1195 checkPrice(o.defaultPrice); |
1196 checkMonthDay(o.start); | 1196 checkMonthDay(o.start); |
1197 } | 1197 } |
1198 buildCounterProrate--; | 1198 buildCounterProrate--; |
1199 } | 1199 } |
1200 | 1200 |
1201 buildUnnamed2914() { | 1201 buildUnnamed2384() { |
1202 var o = new core.List<api.Comment>(); | 1202 var o = new core.List<api.Comment>(); |
1203 o.add(buildComment()); | 1203 o.add(buildComment()); |
1204 o.add(buildComment()); | 1204 o.add(buildComment()); |
1205 return o; | 1205 return o; |
1206 } | 1206 } |
1207 | 1207 |
1208 checkUnnamed2914(core.List<api.Comment> o) { | 1208 checkUnnamed2384(core.List<api.Comment> o) { |
1209 unittest.expect(o, unittest.hasLength(2)); | 1209 unittest.expect(o, unittest.hasLength(2)); |
1210 checkComment(o[0]); | 1210 checkComment(o[0]); |
1211 checkComment(o[1]); | 1211 checkComment(o[1]); |
1212 } | 1212 } |
1213 | 1213 |
1214 core.int buildCounterReview = 0; | 1214 core.int buildCounterReview = 0; |
1215 buildReview() { | 1215 buildReview() { |
1216 var o = new api.Review(); | 1216 var o = new api.Review(); |
1217 buildCounterReview++; | 1217 buildCounterReview++; |
1218 if (buildCounterReview < 3) { | 1218 if (buildCounterReview < 3) { |
1219 o.authorName = "foo"; | 1219 o.authorName = "foo"; |
1220 o.comments = buildUnnamed2914(); | 1220 o.comments = buildUnnamed2384(); |
1221 o.reviewId = "foo"; | 1221 o.reviewId = "foo"; |
1222 } | 1222 } |
1223 buildCounterReview--; | 1223 buildCounterReview--; |
1224 return o; | 1224 return o; |
1225 } | 1225 } |
1226 | 1226 |
1227 checkReview(api.Review o) { | 1227 checkReview(api.Review o) { |
1228 buildCounterReview++; | 1228 buildCounterReview++; |
1229 if (buildCounterReview < 3) { | 1229 if (buildCounterReview < 3) { |
1230 unittest.expect(o.authorName, unittest.equals('foo')); | 1230 unittest.expect(o.authorName, unittest.equals('foo')); |
1231 checkUnnamed2914(o.comments); | 1231 checkUnnamed2384(o.comments); |
1232 unittest.expect(o.reviewId, unittest.equals('foo')); | 1232 unittest.expect(o.reviewId, unittest.equals('foo')); |
1233 } | 1233 } |
1234 buildCounterReview--; | 1234 buildCounterReview--; |
1235 } | 1235 } |
1236 | 1236 |
1237 core.int buildCounterReviewReplyResult = 0; | 1237 core.int buildCounterReviewReplyResult = 0; |
1238 buildReviewReplyResult() { | 1238 buildReviewReplyResult() { |
1239 var o = new api.ReviewReplyResult(); | 1239 var o = new api.ReviewReplyResult(); |
1240 buildCounterReviewReplyResult++; | 1240 buildCounterReviewReplyResult++; |
1241 if (buildCounterReviewReplyResult < 3) { | 1241 if (buildCounterReviewReplyResult < 3) { |
1242 o.lastEdited = buildTimestamp(); | 1242 o.lastEdited = buildTimestamp(); |
1243 o.replyText = "foo"; | 1243 o.replyText = "foo"; |
1244 } | 1244 } |
1245 buildCounterReviewReplyResult--; | 1245 buildCounterReviewReplyResult--; |
1246 return o; | 1246 return o; |
1247 } | 1247 } |
1248 | 1248 |
1249 checkReviewReplyResult(api.ReviewReplyResult o) { | 1249 checkReviewReplyResult(api.ReviewReplyResult o) { |
1250 buildCounterReviewReplyResult++; | 1250 buildCounterReviewReplyResult++; |
1251 if (buildCounterReviewReplyResult < 3) { | 1251 if (buildCounterReviewReplyResult < 3) { |
1252 checkTimestamp(o.lastEdited); | 1252 checkTimestamp(o.lastEdited); |
1253 unittest.expect(o.replyText, unittest.equals('foo')); | 1253 unittest.expect(o.replyText, unittest.equals('foo')); |
1254 } | 1254 } |
1255 buildCounterReviewReplyResult--; | 1255 buildCounterReviewReplyResult--; |
1256 } | 1256 } |
1257 | 1257 |
1258 buildUnnamed2915() { | 1258 buildUnnamed2385() { |
1259 var o = new core.List<api.Review>(); | 1259 var o = new core.List<api.Review>(); |
1260 o.add(buildReview()); | 1260 o.add(buildReview()); |
1261 o.add(buildReview()); | 1261 o.add(buildReview()); |
1262 return o; | 1262 return o; |
1263 } | 1263 } |
1264 | 1264 |
1265 checkUnnamed2915(core.List<api.Review> o) { | 1265 checkUnnamed2385(core.List<api.Review> o) { |
1266 unittest.expect(o, unittest.hasLength(2)); | 1266 unittest.expect(o, unittest.hasLength(2)); |
1267 checkReview(o[0]); | 1267 checkReview(o[0]); |
1268 checkReview(o[1]); | 1268 checkReview(o[1]); |
1269 } | 1269 } |
1270 | 1270 |
1271 core.int buildCounterReviewsListResponse = 0; | 1271 core.int buildCounterReviewsListResponse = 0; |
1272 buildReviewsListResponse() { | 1272 buildReviewsListResponse() { |
1273 var o = new api.ReviewsListResponse(); | 1273 var o = new api.ReviewsListResponse(); |
1274 buildCounterReviewsListResponse++; | 1274 buildCounterReviewsListResponse++; |
1275 if (buildCounterReviewsListResponse < 3) { | 1275 if (buildCounterReviewsListResponse < 3) { |
1276 o.pageInfo = buildPageInfo(); | 1276 o.pageInfo = buildPageInfo(); |
1277 o.reviews = buildUnnamed2915(); | 1277 o.reviews = buildUnnamed2385(); |
1278 o.tokenPagination = buildTokenPagination(); | 1278 o.tokenPagination = buildTokenPagination(); |
1279 } | 1279 } |
1280 buildCounterReviewsListResponse--; | 1280 buildCounterReviewsListResponse--; |
1281 return o; | 1281 return o; |
1282 } | 1282 } |
1283 | 1283 |
1284 checkReviewsListResponse(api.ReviewsListResponse o) { | 1284 checkReviewsListResponse(api.ReviewsListResponse o) { |
1285 buildCounterReviewsListResponse++; | 1285 buildCounterReviewsListResponse++; |
1286 if (buildCounterReviewsListResponse < 3) { | 1286 if (buildCounterReviewsListResponse < 3) { |
1287 checkPageInfo(o.pageInfo); | 1287 checkPageInfo(o.pageInfo); |
1288 checkUnnamed2915(o.reviews); | 1288 checkUnnamed2385(o.reviews); |
1289 checkTokenPagination(o.tokenPagination); | 1289 checkTokenPagination(o.tokenPagination); |
1290 } | 1290 } |
1291 buildCounterReviewsListResponse--; | 1291 buildCounterReviewsListResponse--; |
1292 } | 1292 } |
1293 | 1293 |
1294 core.int buildCounterReviewsReplyRequest = 0; | 1294 core.int buildCounterReviewsReplyRequest = 0; |
1295 buildReviewsReplyRequest() { | 1295 buildReviewsReplyRequest() { |
1296 var o = new api.ReviewsReplyRequest(); | 1296 var o = new api.ReviewsReplyRequest(); |
1297 buildCounterReviewsReplyRequest++; | 1297 buildCounterReviewsReplyRequest++; |
1298 if (buildCounterReviewsReplyRequest < 3) { | 1298 if (buildCounterReviewsReplyRequest < 3) { |
(...skipping 23 matching lines...) Expand all Loading... |
1322 } | 1322 } |
1323 | 1323 |
1324 checkReviewsReplyResponse(api.ReviewsReplyResponse o) { | 1324 checkReviewsReplyResponse(api.ReviewsReplyResponse o) { |
1325 buildCounterReviewsReplyResponse++; | 1325 buildCounterReviewsReplyResponse++; |
1326 if (buildCounterReviewsReplyResponse < 3) { | 1326 if (buildCounterReviewsReplyResponse < 3) { |
1327 checkReviewReplyResult(o.result); | 1327 checkReviewReplyResult(o.result); |
1328 } | 1328 } |
1329 buildCounterReviewsReplyResponse--; | 1329 buildCounterReviewsReplyResponse--; |
1330 } | 1330 } |
1331 | 1331 |
1332 buildUnnamed2916() { | 1332 buildUnnamed2386() { |
1333 var o = new core.List<api.Prorate>(); | 1333 var o = new core.List<api.Prorate>(); |
1334 o.add(buildProrate()); | 1334 o.add(buildProrate()); |
1335 o.add(buildProrate()); | 1335 o.add(buildProrate()); |
1336 return o; | 1336 return o; |
1337 } | 1337 } |
1338 | 1338 |
1339 checkUnnamed2916(core.List<api.Prorate> o) { | 1339 checkUnnamed2386(core.List<api.Prorate> o) { |
1340 unittest.expect(o, unittest.hasLength(2)); | 1340 unittest.expect(o, unittest.hasLength(2)); |
1341 checkProrate(o[0]); | 1341 checkProrate(o[0]); |
1342 checkProrate(o[1]); | 1342 checkProrate(o[1]); |
1343 } | 1343 } |
1344 | 1344 |
1345 core.int buildCounterSeason = 0; | 1345 core.int buildCounterSeason = 0; |
1346 buildSeason() { | 1346 buildSeason() { |
1347 var o = new api.Season(); | 1347 var o = new api.Season(); |
1348 buildCounterSeason++; | 1348 buildCounterSeason++; |
1349 if (buildCounterSeason < 3) { | 1349 if (buildCounterSeason < 3) { |
1350 o.end = buildMonthDay(); | 1350 o.end = buildMonthDay(); |
1351 o.prorations = buildUnnamed2916(); | 1351 o.prorations = buildUnnamed2386(); |
1352 o.start = buildMonthDay(); | 1352 o.start = buildMonthDay(); |
1353 } | 1353 } |
1354 buildCounterSeason--; | 1354 buildCounterSeason--; |
1355 return o; | 1355 return o; |
1356 } | 1356 } |
1357 | 1357 |
1358 checkSeason(api.Season o) { | 1358 checkSeason(api.Season o) { |
1359 buildCounterSeason++; | 1359 buildCounterSeason++; |
1360 if (buildCounterSeason < 3) { | 1360 if (buildCounterSeason < 3) { |
1361 checkMonthDay(o.end); | 1361 checkMonthDay(o.end); |
1362 checkUnnamed2916(o.prorations); | 1362 checkUnnamed2386(o.prorations); |
1363 checkMonthDay(o.start); | 1363 checkMonthDay(o.start); |
1364 } | 1364 } |
1365 buildCounterSeason--; | 1365 buildCounterSeason--; |
1366 } | 1366 } |
1367 | 1367 |
1368 core.int buildCounterSubscriptionDeferralInfo = 0; | 1368 core.int buildCounterSubscriptionDeferralInfo = 0; |
1369 buildSubscriptionDeferralInfo() { | 1369 buildSubscriptionDeferralInfo() { |
1370 var o = new api.SubscriptionDeferralInfo(); | 1370 var o = new api.SubscriptionDeferralInfo(); |
1371 buildCounterSubscriptionDeferralInfo++; | 1371 buildCounterSubscriptionDeferralInfo++; |
1372 if (buildCounterSubscriptionDeferralInfo < 3) { | 1372 if (buildCounterSubscriptionDeferralInfo < 3) { |
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1456 } | 1456 } |
1457 | 1457 |
1458 checkSubscriptionPurchasesDeferResponse(api.SubscriptionPurchasesDeferResponse o
) { | 1458 checkSubscriptionPurchasesDeferResponse(api.SubscriptionPurchasesDeferResponse o
) { |
1459 buildCounterSubscriptionPurchasesDeferResponse++; | 1459 buildCounterSubscriptionPurchasesDeferResponse++; |
1460 if (buildCounterSubscriptionPurchasesDeferResponse < 3) { | 1460 if (buildCounterSubscriptionPurchasesDeferResponse < 3) { |
1461 unittest.expect(o.newExpiryTimeMillis, unittest.equals('foo')); | 1461 unittest.expect(o.newExpiryTimeMillis, unittest.equals('foo')); |
1462 } | 1462 } |
1463 buildCounterSubscriptionPurchasesDeferResponse--; | 1463 buildCounterSubscriptionPurchasesDeferResponse--; |
1464 } | 1464 } |
1465 | 1465 |
1466 buildUnnamed2917() { | 1466 buildUnnamed2387() { |
1467 var o = new core.List<core.String>(); | 1467 var o = new core.List<core.String>(); |
1468 o.add("foo"); | 1468 o.add("foo"); |
1469 o.add("foo"); | 1469 o.add("foo"); |
1470 return o; | 1470 return o; |
1471 } | 1471 } |
1472 | 1472 |
1473 checkUnnamed2917(core.List<core.String> o) { | 1473 checkUnnamed2387(core.List<core.String> o) { |
1474 unittest.expect(o, unittest.hasLength(2)); | 1474 unittest.expect(o, unittest.hasLength(2)); |
1475 unittest.expect(o[0], unittest.equals('foo')); | 1475 unittest.expect(o[0], unittest.equals('foo')); |
1476 unittest.expect(o[1], unittest.equals('foo')); | 1476 unittest.expect(o[1], unittest.equals('foo')); |
1477 } | 1477 } |
1478 | 1478 |
1479 buildUnnamed2918() { | 1479 buildUnnamed2388() { |
1480 var o = new core.List<core.String>(); | 1480 var o = new core.List<core.String>(); |
1481 o.add("foo"); | 1481 o.add("foo"); |
1482 o.add("foo"); | 1482 o.add("foo"); |
1483 return o; | 1483 return o; |
1484 } | 1484 } |
1485 | 1485 |
1486 checkUnnamed2918(core.List<core.String> o) { | 1486 checkUnnamed2388(core.List<core.String> o) { |
1487 unittest.expect(o, unittest.hasLength(2)); | 1487 unittest.expect(o, unittest.hasLength(2)); |
1488 unittest.expect(o[0], unittest.equals('foo')); | 1488 unittest.expect(o[0], unittest.equals('foo')); |
1489 unittest.expect(o[1], unittest.equals('foo')); | 1489 unittest.expect(o[1], unittest.equals('foo')); |
1490 } | 1490 } |
1491 | 1491 |
1492 core.int buildCounterTesters = 0; | 1492 core.int buildCounterTesters = 0; |
1493 buildTesters() { | 1493 buildTesters() { |
1494 var o = new api.Testers(); | 1494 var o = new api.Testers(); |
1495 buildCounterTesters++; | 1495 buildCounterTesters++; |
1496 if (buildCounterTesters < 3) { | 1496 if (buildCounterTesters < 3) { |
1497 o.googleGroups = buildUnnamed2917(); | 1497 o.googleGroups = buildUnnamed2387(); |
1498 o.googlePlusCommunities = buildUnnamed2918(); | 1498 o.googlePlusCommunities = buildUnnamed2388(); |
1499 } | 1499 } |
1500 buildCounterTesters--; | 1500 buildCounterTesters--; |
1501 return o; | 1501 return o; |
1502 } | 1502 } |
1503 | 1503 |
1504 checkTesters(api.Testers o) { | 1504 checkTesters(api.Testers o) { |
1505 buildCounterTesters++; | 1505 buildCounterTesters++; |
1506 if (buildCounterTesters < 3) { | 1506 if (buildCounterTesters < 3) { |
1507 checkUnnamed2917(o.googleGroups); | 1507 checkUnnamed2387(o.googleGroups); |
1508 checkUnnamed2918(o.googlePlusCommunities); | 1508 checkUnnamed2388(o.googlePlusCommunities); |
1509 } | 1509 } |
1510 buildCounterTesters--; | 1510 buildCounterTesters--; |
1511 } | 1511 } |
1512 | 1512 |
1513 core.int buildCounterTimestamp = 0; | 1513 core.int buildCounterTimestamp = 0; |
1514 buildTimestamp() { | 1514 buildTimestamp() { |
1515 var o = new api.Timestamp(); | 1515 var o = new api.Timestamp(); |
1516 buildCounterTimestamp++; | 1516 buildCounterTimestamp++; |
1517 if (buildCounterTimestamp < 3) { | 1517 if (buildCounterTimestamp < 3) { |
1518 o.nanos = 42; | 1518 o.nanos = 42; |
(...skipping 26 matching lines...) Expand all Loading... |
1545 | 1545 |
1546 checkTokenPagination(api.TokenPagination o) { | 1546 checkTokenPagination(api.TokenPagination o) { |
1547 buildCounterTokenPagination++; | 1547 buildCounterTokenPagination++; |
1548 if (buildCounterTokenPagination < 3) { | 1548 if (buildCounterTokenPagination < 3) { |
1549 unittest.expect(o.nextPageToken, unittest.equals('foo')); | 1549 unittest.expect(o.nextPageToken, unittest.equals('foo')); |
1550 unittest.expect(o.previousPageToken, unittest.equals('foo')); | 1550 unittest.expect(o.previousPageToken, unittest.equals('foo')); |
1551 } | 1551 } |
1552 buildCounterTokenPagination--; | 1552 buildCounterTokenPagination--; |
1553 } | 1553 } |
1554 | 1554 |
1555 buildUnnamed2919() { | 1555 buildUnnamed2389() { |
1556 var o = new core.List<core.int>(); | 1556 var o = new core.List<core.int>(); |
1557 o.add(42); | 1557 o.add(42); |
1558 o.add(42); | 1558 o.add(42); |
1559 return o; | 1559 return o; |
1560 } | 1560 } |
1561 | 1561 |
1562 checkUnnamed2919(core.List<core.int> o) { | 1562 checkUnnamed2389(core.List<core.int> o) { |
1563 unittest.expect(o, unittest.hasLength(2)); | 1563 unittest.expect(o, unittest.hasLength(2)); |
1564 unittest.expect(o[0], unittest.equals(42)); | 1564 unittest.expect(o[0], unittest.equals(42)); |
1565 unittest.expect(o[1], unittest.equals(42)); | 1565 unittest.expect(o[1], unittest.equals(42)); |
1566 } | 1566 } |
1567 | 1567 |
1568 core.int buildCounterTrack = 0; | 1568 core.int buildCounterTrack = 0; |
1569 buildTrack() { | 1569 buildTrack() { |
1570 var o = new api.Track(); | 1570 var o = new api.Track(); |
1571 buildCounterTrack++; | 1571 buildCounterTrack++; |
1572 if (buildCounterTrack < 3) { | 1572 if (buildCounterTrack < 3) { |
1573 o.track = "foo"; | 1573 o.track = "foo"; |
1574 o.userFraction = 42.0; | 1574 o.userFraction = 42.0; |
1575 o.versionCodes = buildUnnamed2919(); | 1575 o.versionCodes = buildUnnamed2389(); |
1576 } | 1576 } |
1577 buildCounterTrack--; | 1577 buildCounterTrack--; |
1578 return o; | 1578 return o; |
1579 } | 1579 } |
1580 | 1580 |
1581 checkTrack(api.Track o) { | 1581 checkTrack(api.Track o) { |
1582 buildCounterTrack++; | 1582 buildCounterTrack++; |
1583 if (buildCounterTrack < 3) { | 1583 if (buildCounterTrack < 3) { |
1584 unittest.expect(o.track, unittest.equals('foo')); | 1584 unittest.expect(o.track, unittest.equals('foo')); |
1585 unittest.expect(o.userFraction, unittest.equals(42.0)); | 1585 unittest.expect(o.userFraction, unittest.equals(42.0)); |
1586 checkUnnamed2919(o.versionCodes); | 1586 checkUnnamed2389(o.versionCodes); |
1587 } | 1587 } |
1588 buildCounterTrack--; | 1588 buildCounterTrack--; |
1589 } | 1589 } |
1590 | 1590 |
1591 buildUnnamed2920() { | 1591 buildUnnamed2390() { |
1592 var o = new core.List<api.Track>(); | 1592 var o = new core.List<api.Track>(); |
1593 o.add(buildTrack()); | 1593 o.add(buildTrack()); |
1594 o.add(buildTrack()); | 1594 o.add(buildTrack()); |
1595 return o; | 1595 return o; |
1596 } | 1596 } |
1597 | 1597 |
1598 checkUnnamed2920(core.List<api.Track> o) { | 1598 checkUnnamed2390(core.List<api.Track> o) { |
1599 unittest.expect(o, unittest.hasLength(2)); | 1599 unittest.expect(o, unittest.hasLength(2)); |
1600 checkTrack(o[0]); | 1600 checkTrack(o[0]); |
1601 checkTrack(o[1]); | 1601 checkTrack(o[1]); |
1602 } | 1602 } |
1603 | 1603 |
1604 core.int buildCounterTracksListResponse = 0; | 1604 core.int buildCounterTracksListResponse = 0; |
1605 buildTracksListResponse() { | 1605 buildTracksListResponse() { |
1606 var o = new api.TracksListResponse(); | 1606 var o = new api.TracksListResponse(); |
1607 buildCounterTracksListResponse++; | 1607 buildCounterTracksListResponse++; |
1608 if (buildCounterTracksListResponse < 3) { | 1608 if (buildCounterTracksListResponse < 3) { |
1609 o.kind = "foo"; | 1609 o.kind = "foo"; |
1610 o.tracks = buildUnnamed2920(); | 1610 o.tracks = buildUnnamed2390(); |
1611 } | 1611 } |
1612 buildCounterTracksListResponse--; | 1612 buildCounterTracksListResponse--; |
1613 return o; | 1613 return o; |
1614 } | 1614 } |
1615 | 1615 |
1616 checkTracksListResponse(api.TracksListResponse o) { | 1616 checkTracksListResponse(api.TracksListResponse o) { |
1617 buildCounterTracksListResponse++; | 1617 buildCounterTracksListResponse++; |
1618 if (buildCounterTracksListResponse < 3) { | 1618 if (buildCounterTracksListResponse < 3) { |
1619 unittest.expect(o.kind, unittest.equals('foo')); | 1619 unittest.expect(o.kind, unittest.equals('foo')); |
1620 checkUnnamed2920(o.tracks); | 1620 checkUnnamed2390(o.tracks); |
1621 } | 1621 } |
1622 buildCounterTracksListResponse--; | 1622 buildCounterTracksListResponse--; |
1623 } | 1623 } |
1624 | 1624 |
1625 core.int buildCounterUserComment = 0; | 1625 core.int buildCounterUserComment = 0; |
1626 buildUserComment() { | 1626 buildUserComment() { |
1627 var o = new api.UserComment(); | 1627 var o = new api.UserComment(); |
1628 buildCounterUserComment++; | 1628 buildCounterUserComment++; |
1629 if (buildCounterUserComment < 3) { | 1629 if (buildCounterUserComment < 3) { |
1630 o.androidOsVersion = 42; | 1630 o.androidOsVersion = 42; |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1681 buildCounterVoidedPurchase++; | 1681 buildCounterVoidedPurchase++; |
1682 if (buildCounterVoidedPurchase < 3) { | 1682 if (buildCounterVoidedPurchase < 3) { |
1683 unittest.expect(o.kind, unittest.equals('foo')); | 1683 unittest.expect(o.kind, unittest.equals('foo')); |
1684 unittest.expect(o.purchaseTimeMillis, unittest.equals('foo')); | 1684 unittest.expect(o.purchaseTimeMillis, unittest.equals('foo')); |
1685 unittest.expect(o.purchaseToken, unittest.equals('foo')); | 1685 unittest.expect(o.purchaseToken, unittest.equals('foo')); |
1686 unittest.expect(o.voidedTimeMillis, unittest.equals('foo')); | 1686 unittest.expect(o.voidedTimeMillis, unittest.equals('foo')); |
1687 } | 1687 } |
1688 buildCounterVoidedPurchase--; | 1688 buildCounterVoidedPurchase--; |
1689 } | 1689 } |
1690 | 1690 |
1691 buildUnnamed2921() { | 1691 buildUnnamed2391() { |
1692 var o = new core.List<api.VoidedPurchase>(); | 1692 var o = new core.List<api.VoidedPurchase>(); |
1693 o.add(buildVoidedPurchase()); | 1693 o.add(buildVoidedPurchase()); |
1694 o.add(buildVoidedPurchase()); | 1694 o.add(buildVoidedPurchase()); |
1695 return o; | 1695 return o; |
1696 } | 1696 } |
1697 | 1697 |
1698 checkUnnamed2921(core.List<api.VoidedPurchase> o) { | 1698 checkUnnamed2391(core.List<api.VoidedPurchase> o) { |
1699 unittest.expect(o, unittest.hasLength(2)); | 1699 unittest.expect(o, unittest.hasLength(2)); |
1700 checkVoidedPurchase(o[0]); | 1700 checkVoidedPurchase(o[0]); |
1701 checkVoidedPurchase(o[1]); | 1701 checkVoidedPurchase(o[1]); |
1702 } | 1702 } |
1703 | 1703 |
1704 core.int buildCounterVoidedPurchasesListResponse = 0; | 1704 core.int buildCounterVoidedPurchasesListResponse = 0; |
1705 buildVoidedPurchasesListResponse() { | 1705 buildVoidedPurchasesListResponse() { |
1706 var o = new api.VoidedPurchasesListResponse(); | 1706 var o = new api.VoidedPurchasesListResponse(); |
1707 buildCounterVoidedPurchasesListResponse++; | 1707 buildCounterVoidedPurchasesListResponse++; |
1708 if (buildCounterVoidedPurchasesListResponse < 3) { | 1708 if (buildCounterVoidedPurchasesListResponse < 3) { |
1709 o.pageInfo = buildPageInfo(); | 1709 o.pageInfo = buildPageInfo(); |
1710 o.tokenPagination = buildTokenPagination(); | 1710 o.tokenPagination = buildTokenPagination(); |
1711 o.voidedPurchases = buildUnnamed2921(); | 1711 o.voidedPurchases = buildUnnamed2391(); |
1712 } | 1712 } |
1713 buildCounterVoidedPurchasesListResponse--; | 1713 buildCounterVoidedPurchasesListResponse--; |
1714 return o; | 1714 return o; |
1715 } | 1715 } |
1716 | 1716 |
1717 checkVoidedPurchasesListResponse(api.VoidedPurchasesListResponse o) { | 1717 checkVoidedPurchasesListResponse(api.VoidedPurchasesListResponse o) { |
1718 buildCounterVoidedPurchasesListResponse++; | 1718 buildCounterVoidedPurchasesListResponse++; |
1719 if (buildCounterVoidedPurchasesListResponse < 3) { | 1719 if (buildCounterVoidedPurchasesListResponse < 3) { |
1720 checkPageInfo(o.pageInfo); | 1720 checkPageInfo(o.pageInfo); |
1721 checkTokenPagination(o.tokenPagination); | 1721 checkTokenPagination(o.tokenPagination); |
1722 checkUnnamed2921(o.voidedPurchases); | 1722 checkUnnamed2391(o.voidedPurchases); |
1723 } | 1723 } |
1724 buildCounterVoidedPurchasesListResponse--; | 1724 buildCounterVoidedPurchasesListResponse--; |
1725 } | 1725 } |
1726 | 1726 |
1727 | 1727 |
1728 main() { | 1728 main() { |
1729 unittest.group("obj-schema-Apk", () { | 1729 unittest.group("obj-schema-Apk", () { |
1730 unittest.test("to-json--from-json", () { | 1730 unittest.test("to-json--from-json", () { |
1731 var o = buildApk(); | 1731 var o = buildApk(); |
1732 var od = new api.Apk.fromJson(o.toJson()); | 1732 var od = new api.Apk.fromJson(o.toJson()); |
(...skipping 533 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2266 }); | 2266 }); |
2267 | 2267 |
2268 | 2268 |
2269 unittest.group("resource-EditsResourceApi", () { | 2269 unittest.group("resource-EditsResourceApi", () { |
2270 unittest.test("method--commit", () { | 2270 unittest.test("method--commit", () { |
2271 | 2271 |
2272 var mock = new HttpServerMock(); | 2272 var mock = new HttpServerMock(); |
2273 api.EditsResourceApi res = new api.AndroidpublisherApi(mock).edits; | 2273 api.EditsResourceApi res = new api.AndroidpublisherApi(mock).edits; |
2274 var arg_packageName = "foo"; | 2274 var arg_packageName = "foo"; |
2275 var arg_editId = "foo"; | 2275 var arg_editId = "foo"; |
2276 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2276 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2277 var path = (req.url).path; | 2277 var path = (req.url).path; |
2278 var pathOffset = 0; | 2278 var pathOffset = 0; |
2279 var index; | 2279 var index; |
2280 var subPart; | 2280 var subPart; |
2281 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2281 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2282 pathOffset += 1; | 2282 pathOffset += 1; |
2283 | 2283 |
2284 var query = (req.url).query; | 2284 var query = (req.url).query; |
2285 var queryOffset = 0; | 2285 var queryOffset = 0; |
2286 var queryMap = {}; | 2286 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
2298 } | 2298 } |
2299 } | 2299 } |
2300 | 2300 |
2301 | 2301 |
2302 var h = { | 2302 var h = { |
2303 "content-type" : "application/json; charset=utf-8", | 2303 "content-type" : "application/json; charset=utf-8", |
2304 }; | 2304 }; |
2305 var resp = convert.JSON.encode(buildAppEdit()); | 2305 var resp = convert.JSON.encode(buildAppEdit()); |
2306 return new async.Future.value(stringResponse(200, h, resp)); | 2306 return new async.Future.value(stringResponse(200, h, resp)); |
2307 }), true); | 2307 }), true); |
2308 res.commit(arg_packageName, arg_editId).then(unittest.expectAsync(((api.Ap
pEdit response) { | 2308 res.commit(arg_packageName, arg_editId).then(unittest.expectAsync1(((api.A
ppEdit response) { |
2309 checkAppEdit(response); | 2309 checkAppEdit(response); |
2310 }))); | 2310 }))); |
2311 }); | 2311 }); |
2312 | 2312 |
2313 unittest.test("method--delete", () { | 2313 unittest.test("method--delete", () { |
2314 | 2314 |
2315 var mock = new HttpServerMock(); | 2315 var mock = new HttpServerMock(); |
2316 api.EditsResourceApi res = new api.AndroidpublisherApi(mock).edits; | 2316 api.EditsResourceApi res = new api.AndroidpublisherApi(mock).edits; |
2317 var arg_packageName = "foo"; | 2317 var arg_packageName = "foo"; |
2318 var arg_editId = "foo"; | 2318 var arg_editId = "foo"; |
2319 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2319 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2320 var path = (req.url).path; | 2320 var path = (req.url).path; |
2321 var pathOffset = 0; | 2321 var pathOffset = 0; |
2322 var index; | 2322 var index; |
2323 var subPart; | 2323 var subPart; |
2324 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2324 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2325 pathOffset += 1; | 2325 pathOffset += 1; |
2326 | 2326 |
2327 var query = (req.url).query; | 2327 var query = (req.url).query; |
2328 var queryOffset = 0; | 2328 var queryOffset = 0; |
2329 var queryMap = {}; | 2329 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
2341 } | 2341 } |
2342 } | 2342 } |
2343 | 2343 |
2344 | 2344 |
2345 var h = { | 2345 var h = { |
2346 "content-type" : "application/json; charset=utf-8", | 2346 "content-type" : "application/json; charset=utf-8", |
2347 }; | 2347 }; |
2348 var resp = ""; | 2348 var resp = ""; |
2349 return new async.Future.value(stringResponse(200, h, resp)); | 2349 return new async.Future.value(stringResponse(200, h, resp)); |
2350 }), true); | 2350 }), true); |
2351 res.delete(arg_packageName, arg_editId).then(unittest.expectAsync((_) {}))
; | 2351 res.delete(arg_packageName, arg_editId).then(unittest.expectAsync1((_) {})
); |
2352 }); | 2352 }); |
2353 | 2353 |
2354 unittest.test("method--get", () { | 2354 unittest.test("method--get", () { |
2355 | 2355 |
2356 var mock = new HttpServerMock(); | 2356 var mock = new HttpServerMock(); |
2357 api.EditsResourceApi res = new api.AndroidpublisherApi(mock).edits; | 2357 api.EditsResourceApi res = new api.AndroidpublisherApi(mock).edits; |
2358 var arg_packageName = "foo"; | 2358 var arg_packageName = "foo"; |
2359 var arg_editId = "foo"; | 2359 var arg_editId = "foo"; |
2360 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2360 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2361 var path = (req.url).path; | 2361 var path = (req.url).path; |
2362 var pathOffset = 0; | 2362 var pathOffset = 0; |
2363 var index; | 2363 var index; |
2364 var subPart; | 2364 var subPart; |
2365 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2365 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2366 pathOffset += 1; | 2366 pathOffset += 1; |
2367 | 2367 |
2368 var query = (req.url).query; | 2368 var query = (req.url).query; |
2369 var queryOffset = 0; | 2369 var queryOffset = 0; |
2370 var queryMap = {}; | 2370 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
2382 } | 2382 } |
2383 } | 2383 } |
2384 | 2384 |
2385 | 2385 |
2386 var h = { | 2386 var h = { |
2387 "content-type" : "application/json; charset=utf-8", | 2387 "content-type" : "application/json; charset=utf-8", |
2388 }; | 2388 }; |
2389 var resp = convert.JSON.encode(buildAppEdit()); | 2389 var resp = convert.JSON.encode(buildAppEdit()); |
2390 return new async.Future.value(stringResponse(200, h, resp)); | 2390 return new async.Future.value(stringResponse(200, h, resp)); |
2391 }), true); | 2391 }), true); |
2392 res.get(arg_packageName, arg_editId).then(unittest.expectAsync(((api.AppEd
it response) { | 2392 res.get(arg_packageName, arg_editId).then(unittest.expectAsync1(((api.AppE
dit response) { |
2393 checkAppEdit(response); | 2393 checkAppEdit(response); |
2394 }))); | 2394 }))); |
2395 }); | 2395 }); |
2396 | 2396 |
2397 unittest.test("method--insert", () { | 2397 unittest.test("method--insert", () { |
2398 | 2398 |
2399 var mock = new HttpServerMock(); | 2399 var mock = new HttpServerMock(); |
2400 api.EditsResourceApi res = new api.AndroidpublisherApi(mock).edits; | 2400 api.EditsResourceApi res = new api.AndroidpublisherApi(mock).edits; |
2401 var arg_request = buildAppEdit(); | 2401 var arg_request = buildAppEdit(); |
2402 var arg_packageName = "foo"; | 2402 var arg_packageName = "foo"; |
2403 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2403 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2404 var obj = new api.AppEdit.fromJson(json); | 2404 var obj = new api.AppEdit.fromJson(json); |
2405 checkAppEdit(obj); | 2405 checkAppEdit(obj); |
2406 | 2406 |
2407 var path = (req.url).path; | 2407 var path = (req.url).path; |
2408 var pathOffset = 0; | 2408 var pathOffset = 0; |
2409 var index; | 2409 var index; |
2410 var subPart; | 2410 var subPart; |
2411 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2411 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2412 pathOffset += 1; | 2412 pathOffset += 1; |
2413 | 2413 |
(...skipping 14 matching lines...) Expand all Loading... |
2428 } | 2428 } |
2429 } | 2429 } |
2430 | 2430 |
2431 | 2431 |
2432 var h = { | 2432 var h = { |
2433 "content-type" : "application/json; charset=utf-8", | 2433 "content-type" : "application/json; charset=utf-8", |
2434 }; | 2434 }; |
2435 var resp = convert.JSON.encode(buildAppEdit()); | 2435 var resp = convert.JSON.encode(buildAppEdit()); |
2436 return new async.Future.value(stringResponse(200, h, resp)); | 2436 return new async.Future.value(stringResponse(200, h, resp)); |
2437 }), true); | 2437 }), true); |
2438 res.insert(arg_request, arg_packageName).then(unittest.expectAsync(((api.A
ppEdit response) { | 2438 res.insert(arg_request, arg_packageName).then(unittest.expectAsync1(((api.
AppEdit response) { |
2439 checkAppEdit(response); | 2439 checkAppEdit(response); |
2440 }))); | 2440 }))); |
2441 }); | 2441 }); |
2442 | 2442 |
2443 unittest.test("method--validate", () { | 2443 unittest.test("method--validate", () { |
2444 | 2444 |
2445 var mock = new HttpServerMock(); | 2445 var mock = new HttpServerMock(); |
2446 api.EditsResourceApi res = new api.AndroidpublisherApi(mock).edits; | 2446 api.EditsResourceApi res = new api.AndroidpublisherApi(mock).edits; |
2447 var arg_packageName = "foo"; | 2447 var arg_packageName = "foo"; |
2448 var arg_editId = "foo"; | 2448 var arg_editId = "foo"; |
2449 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2449 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2450 var path = (req.url).path; | 2450 var path = (req.url).path; |
2451 var pathOffset = 0; | 2451 var pathOffset = 0; |
2452 var index; | 2452 var index; |
2453 var subPart; | 2453 var subPart; |
2454 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2454 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2455 pathOffset += 1; | 2455 pathOffset += 1; |
2456 | 2456 |
2457 var query = (req.url).query; | 2457 var query = (req.url).query; |
2458 var queryOffset = 0; | 2458 var queryOffset = 0; |
2459 var queryMap = {}; | 2459 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
2471 } | 2471 } |
2472 } | 2472 } |
2473 | 2473 |
2474 | 2474 |
2475 var h = { | 2475 var h = { |
2476 "content-type" : "application/json; charset=utf-8", | 2476 "content-type" : "application/json; charset=utf-8", |
2477 }; | 2477 }; |
2478 var resp = convert.JSON.encode(buildAppEdit()); | 2478 var resp = convert.JSON.encode(buildAppEdit()); |
2479 return new async.Future.value(stringResponse(200, h, resp)); | 2479 return new async.Future.value(stringResponse(200, h, resp)); |
2480 }), true); | 2480 }), true); |
2481 res.validate(arg_packageName, arg_editId).then(unittest.expectAsync(((api.
AppEdit response) { | 2481 res.validate(arg_packageName, arg_editId).then(unittest.expectAsync1(((api
.AppEdit response) { |
2482 checkAppEdit(response); | 2482 checkAppEdit(response); |
2483 }))); | 2483 }))); |
2484 }); | 2484 }); |
2485 | 2485 |
2486 }); | 2486 }); |
2487 | 2487 |
2488 | 2488 |
2489 unittest.group("resource-EditsApklistingsResourceApi", () { | 2489 unittest.group("resource-EditsApklistingsResourceApi", () { |
2490 unittest.test("method--delete", () { | 2490 unittest.test("method--delete", () { |
2491 | 2491 |
2492 var mock = new HttpServerMock(); | 2492 var mock = new HttpServerMock(); |
2493 api.EditsApklistingsResourceApi res = new api.AndroidpublisherApi(mock).ed
its.apklistings; | 2493 api.EditsApklistingsResourceApi res = new api.AndroidpublisherApi(mock).ed
its.apklistings; |
2494 var arg_packageName = "foo"; | 2494 var arg_packageName = "foo"; |
2495 var arg_editId = "foo"; | 2495 var arg_editId = "foo"; |
2496 var arg_apkVersionCode = 42; | 2496 var arg_apkVersionCode = 42; |
2497 var arg_language = "foo"; | 2497 var arg_language = "foo"; |
2498 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2498 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2499 var path = (req.url).path; | 2499 var path = (req.url).path; |
2500 var pathOffset = 0; | 2500 var pathOffset = 0; |
2501 var index; | 2501 var index; |
2502 var subPart; | 2502 var subPart; |
2503 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2503 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2504 pathOffset += 1; | 2504 pathOffset += 1; |
2505 | 2505 |
2506 var query = (req.url).query; | 2506 var query = (req.url).query; |
2507 var queryOffset = 0; | 2507 var queryOffset = 0; |
2508 var queryMap = {}; | 2508 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
2520 } | 2520 } |
2521 } | 2521 } |
2522 | 2522 |
2523 | 2523 |
2524 var h = { | 2524 var h = { |
2525 "content-type" : "application/json; charset=utf-8", | 2525 "content-type" : "application/json; charset=utf-8", |
2526 }; | 2526 }; |
2527 var resp = ""; | 2527 var resp = ""; |
2528 return new async.Future.value(stringResponse(200, h, resp)); | 2528 return new async.Future.value(stringResponse(200, h, resp)); |
2529 }), true); | 2529 }), true); |
2530 res.delete(arg_packageName, arg_editId, arg_apkVersionCode, arg_language).
then(unittest.expectAsync((_) {})); | 2530 res.delete(arg_packageName, arg_editId, arg_apkVersionCode, arg_language).
then(unittest.expectAsync1((_) {})); |
2531 }); | 2531 }); |
2532 | 2532 |
2533 unittest.test("method--deleteall", () { | 2533 unittest.test("method--deleteall", () { |
2534 | 2534 |
2535 var mock = new HttpServerMock(); | 2535 var mock = new HttpServerMock(); |
2536 api.EditsApklistingsResourceApi res = new api.AndroidpublisherApi(mock).ed
its.apklistings; | 2536 api.EditsApklistingsResourceApi res = new api.AndroidpublisherApi(mock).ed
its.apklistings; |
2537 var arg_packageName = "foo"; | 2537 var arg_packageName = "foo"; |
2538 var arg_editId = "foo"; | 2538 var arg_editId = "foo"; |
2539 var arg_apkVersionCode = 42; | 2539 var arg_apkVersionCode = 42; |
2540 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2540 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2541 var path = (req.url).path; | 2541 var path = (req.url).path; |
2542 var pathOffset = 0; | 2542 var pathOffset = 0; |
2543 var index; | 2543 var index; |
2544 var subPart; | 2544 var subPart; |
2545 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2545 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2546 pathOffset += 1; | 2546 pathOffset += 1; |
2547 | 2547 |
2548 var query = (req.url).query; | 2548 var query = (req.url).query; |
2549 var queryOffset = 0; | 2549 var queryOffset = 0; |
2550 var queryMap = {}; | 2550 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
2562 } | 2562 } |
2563 } | 2563 } |
2564 | 2564 |
2565 | 2565 |
2566 var h = { | 2566 var h = { |
2567 "content-type" : "application/json; charset=utf-8", | 2567 "content-type" : "application/json; charset=utf-8", |
2568 }; | 2568 }; |
2569 var resp = ""; | 2569 var resp = ""; |
2570 return new async.Future.value(stringResponse(200, h, resp)); | 2570 return new async.Future.value(stringResponse(200, h, resp)); |
2571 }), true); | 2571 }), true); |
2572 res.deleteall(arg_packageName, arg_editId, arg_apkVersionCode).then(unitte
st.expectAsync((_) {})); | 2572 res.deleteall(arg_packageName, arg_editId, arg_apkVersionCode).then(unitte
st.expectAsync1((_) {})); |
2573 }); | 2573 }); |
2574 | 2574 |
2575 unittest.test("method--get", () { | 2575 unittest.test("method--get", () { |
2576 | 2576 |
2577 var mock = new HttpServerMock(); | 2577 var mock = new HttpServerMock(); |
2578 api.EditsApklistingsResourceApi res = new api.AndroidpublisherApi(mock).ed
its.apklistings; | 2578 api.EditsApklistingsResourceApi res = new api.AndroidpublisherApi(mock).ed
its.apklistings; |
2579 var arg_packageName = "foo"; | 2579 var arg_packageName = "foo"; |
2580 var arg_editId = "foo"; | 2580 var arg_editId = "foo"; |
2581 var arg_apkVersionCode = 42; | 2581 var arg_apkVersionCode = 42; |
2582 var arg_language = "foo"; | 2582 var arg_language = "foo"; |
2583 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2583 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2584 var path = (req.url).path; | 2584 var path = (req.url).path; |
2585 var pathOffset = 0; | 2585 var pathOffset = 0; |
2586 var index; | 2586 var index; |
2587 var subPart; | 2587 var subPart; |
2588 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2588 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2589 pathOffset += 1; | 2589 pathOffset += 1; |
2590 | 2590 |
2591 var query = (req.url).query; | 2591 var query = (req.url).query; |
2592 var queryOffset = 0; | 2592 var queryOffset = 0; |
2593 var queryMap = {}; | 2593 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
2605 } | 2605 } |
2606 } | 2606 } |
2607 | 2607 |
2608 | 2608 |
2609 var h = { | 2609 var h = { |
2610 "content-type" : "application/json; charset=utf-8", | 2610 "content-type" : "application/json; charset=utf-8", |
2611 }; | 2611 }; |
2612 var resp = convert.JSON.encode(buildApkListing()); | 2612 var resp = convert.JSON.encode(buildApkListing()); |
2613 return new async.Future.value(stringResponse(200, h, resp)); | 2613 return new async.Future.value(stringResponse(200, h, resp)); |
2614 }), true); | 2614 }), true); |
2615 res.get(arg_packageName, arg_editId, arg_apkVersionCode, arg_language).the
n(unittest.expectAsync(((api.ApkListing response) { | 2615 res.get(arg_packageName, arg_editId, arg_apkVersionCode, arg_language).the
n(unittest.expectAsync1(((api.ApkListing response) { |
2616 checkApkListing(response); | 2616 checkApkListing(response); |
2617 }))); | 2617 }))); |
2618 }); | 2618 }); |
2619 | 2619 |
2620 unittest.test("method--list", () { | 2620 unittest.test("method--list", () { |
2621 | 2621 |
2622 var mock = new HttpServerMock(); | 2622 var mock = new HttpServerMock(); |
2623 api.EditsApklistingsResourceApi res = new api.AndroidpublisherApi(mock).ed
its.apklistings; | 2623 api.EditsApklistingsResourceApi res = new api.AndroidpublisherApi(mock).ed
its.apklistings; |
2624 var arg_packageName = "foo"; | 2624 var arg_packageName = "foo"; |
2625 var arg_editId = "foo"; | 2625 var arg_editId = "foo"; |
2626 var arg_apkVersionCode = 42; | 2626 var arg_apkVersionCode = 42; |
2627 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2627 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2628 var path = (req.url).path; | 2628 var path = (req.url).path; |
2629 var pathOffset = 0; | 2629 var pathOffset = 0; |
2630 var index; | 2630 var index; |
2631 var subPart; | 2631 var subPart; |
2632 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2632 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2633 pathOffset += 1; | 2633 pathOffset += 1; |
2634 | 2634 |
2635 var query = (req.url).query; | 2635 var query = (req.url).query; |
2636 var queryOffset = 0; | 2636 var queryOffset = 0; |
2637 var queryMap = {}; | 2637 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
2649 } | 2649 } |
2650 } | 2650 } |
2651 | 2651 |
2652 | 2652 |
2653 var h = { | 2653 var h = { |
2654 "content-type" : "application/json; charset=utf-8", | 2654 "content-type" : "application/json; charset=utf-8", |
2655 }; | 2655 }; |
2656 var resp = convert.JSON.encode(buildApkListingsListResponse()); | 2656 var resp = convert.JSON.encode(buildApkListingsListResponse()); |
2657 return new async.Future.value(stringResponse(200, h, resp)); | 2657 return new async.Future.value(stringResponse(200, h, resp)); |
2658 }), true); | 2658 }), true); |
2659 res.list(arg_packageName, arg_editId, arg_apkVersionCode).then(unittest.ex
pectAsync(((api.ApkListingsListResponse response) { | 2659 res.list(arg_packageName, arg_editId, arg_apkVersionCode).then(unittest.ex
pectAsync1(((api.ApkListingsListResponse response) { |
2660 checkApkListingsListResponse(response); | 2660 checkApkListingsListResponse(response); |
2661 }))); | 2661 }))); |
2662 }); | 2662 }); |
2663 | 2663 |
2664 unittest.test("method--patch", () { | 2664 unittest.test("method--patch", () { |
2665 | 2665 |
2666 var mock = new HttpServerMock(); | 2666 var mock = new HttpServerMock(); |
2667 api.EditsApklistingsResourceApi res = new api.AndroidpublisherApi(mock).ed
its.apklistings; | 2667 api.EditsApklistingsResourceApi res = new api.AndroidpublisherApi(mock).ed
its.apklistings; |
2668 var arg_request = buildApkListing(); | 2668 var arg_request = buildApkListing(); |
2669 var arg_packageName = "foo"; | 2669 var arg_packageName = "foo"; |
2670 var arg_editId = "foo"; | 2670 var arg_editId = "foo"; |
2671 var arg_apkVersionCode = 42; | 2671 var arg_apkVersionCode = 42; |
2672 var arg_language = "foo"; | 2672 var arg_language = "foo"; |
2673 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2673 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2674 var obj = new api.ApkListing.fromJson(json); | 2674 var obj = new api.ApkListing.fromJson(json); |
2675 checkApkListing(obj); | 2675 checkApkListing(obj); |
2676 | 2676 |
2677 var path = (req.url).path; | 2677 var path = (req.url).path; |
2678 var pathOffset = 0; | 2678 var pathOffset = 0; |
2679 var index; | 2679 var index; |
2680 var subPart; | 2680 var subPart; |
2681 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2681 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2682 pathOffset += 1; | 2682 pathOffset += 1; |
2683 | 2683 |
(...skipping 14 matching lines...) Expand all Loading... |
2698 } | 2698 } |
2699 } | 2699 } |
2700 | 2700 |
2701 | 2701 |
2702 var h = { | 2702 var h = { |
2703 "content-type" : "application/json; charset=utf-8", | 2703 "content-type" : "application/json; charset=utf-8", |
2704 }; | 2704 }; |
2705 var resp = convert.JSON.encode(buildApkListing()); | 2705 var resp = convert.JSON.encode(buildApkListing()); |
2706 return new async.Future.value(stringResponse(200, h, resp)); | 2706 return new async.Future.value(stringResponse(200, h, resp)); |
2707 }), true); | 2707 }), true); |
2708 res.patch(arg_request, arg_packageName, arg_editId, arg_apkVersionCode, ar
g_language).then(unittest.expectAsync(((api.ApkListing response) { | 2708 res.patch(arg_request, arg_packageName, arg_editId, arg_apkVersionCode, ar
g_language).then(unittest.expectAsync1(((api.ApkListing response) { |
2709 checkApkListing(response); | 2709 checkApkListing(response); |
2710 }))); | 2710 }))); |
2711 }); | 2711 }); |
2712 | 2712 |
2713 unittest.test("method--update", () { | 2713 unittest.test("method--update", () { |
2714 | 2714 |
2715 var mock = new HttpServerMock(); | 2715 var mock = new HttpServerMock(); |
2716 api.EditsApklistingsResourceApi res = new api.AndroidpublisherApi(mock).ed
its.apklistings; | 2716 api.EditsApklistingsResourceApi res = new api.AndroidpublisherApi(mock).ed
its.apklistings; |
2717 var arg_request = buildApkListing(); | 2717 var arg_request = buildApkListing(); |
2718 var arg_packageName = "foo"; | 2718 var arg_packageName = "foo"; |
2719 var arg_editId = "foo"; | 2719 var arg_editId = "foo"; |
2720 var arg_apkVersionCode = 42; | 2720 var arg_apkVersionCode = 42; |
2721 var arg_language = "foo"; | 2721 var arg_language = "foo"; |
2722 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2722 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2723 var obj = new api.ApkListing.fromJson(json); | 2723 var obj = new api.ApkListing.fromJson(json); |
2724 checkApkListing(obj); | 2724 checkApkListing(obj); |
2725 | 2725 |
2726 var path = (req.url).path; | 2726 var path = (req.url).path; |
2727 var pathOffset = 0; | 2727 var pathOffset = 0; |
2728 var index; | 2728 var index; |
2729 var subPart; | 2729 var subPart; |
2730 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2730 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2731 pathOffset += 1; | 2731 pathOffset += 1; |
2732 | 2732 |
(...skipping 14 matching lines...) Expand all Loading... |
2747 } | 2747 } |
2748 } | 2748 } |
2749 | 2749 |
2750 | 2750 |
2751 var h = { | 2751 var h = { |
2752 "content-type" : "application/json; charset=utf-8", | 2752 "content-type" : "application/json; charset=utf-8", |
2753 }; | 2753 }; |
2754 var resp = convert.JSON.encode(buildApkListing()); | 2754 var resp = convert.JSON.encode(buildApkListing()); |
2755 return new async.Future.value(stringResponse(200, h, resp)); | 2755 return new async.Future.value(stringResponse(200, h, resp)); |
2756 }), true); | 2756 }), true); |
2757 res.update(arg_request, arg_packageName, arg_editId, arg_apkVersionCode, a
rg_language).then(unittest.expectAsync(((api.ApkListing response) { | 2757 res.update(arg_request, arg_packageName, arg_editId, arg_apkVersionCode, a
rg_language).then(unittest.expectAsync1(((api.ApkListing response) { |
2758 checkApkListing(response); | 2758 checkApkListing(response); |
2759 }))); | 2759 }))); |
2760 }); | 2760 }); |
2761 | 2761 |
2762 }); | 2762 }); |
2763 | 2763 |
2764 | 2764 |
2765 unittest.group("resource-EditsApksResourceApi", () { | 2765 unittest.group("resource-EditsApksResourceApi", () { |
2766 unittest.test("method--addexternallyhosted", () { | 2766 unittest.test("method--addexternallyhosted", () { |
2767 | 2767 |
2768 var mock = new HttpServerMock(); | 2768 var mock = new HttpServerMock(); |
2769 api.EditsApksResourceApi res = new api.AndroidpublisherApi(mock).edits.apk
s; | 2769 api.EditsApksResourceApi res = new api.AndroidpublisherApi(mock).edits.apk
s; |
2770 var arg_request = buildApksAddExternallyHostedRequest(); | 2770 var arg_request = buildApksAddExternallyHostedRequest(); |
2771 var arg_packageName = "foo"; | 2771 var arg_packageName = "foo"; |
2772 var arg_editId = "foo"; | 2772 var arg_editId = "foo"; |
2773 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2773 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2774 var obj = new api.ApksAddExternallyHostedRequest.fromJson(json); | 2774 var obj = new api.ApksAddExternallyHostedRequest.fromJson(json); |
2775 checkApksAddExternallyHostedRequest(obj); | 2775 checkApksAddExternallyHostedRequest(obj); |
2776 | 2776 |
2777 var path = (req.url).path; | 2777 var path = (req.url).path; |
2778 var pathOffset = 0; | 2778 var pathOffset = 0; |
2779 var index; | 2779 var index; |
2780 var subPart; | 2780 var subPart; |
2781 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2781 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2782 pathOffset += 1; | 2782 pathOffset += 1; |
2783 | 2783 |
(...skipping 14 matching lines...) Expand all Loading... |
2798 } | 2798 } |
2799 } | 2799 } |
2800 | 2800 |
2801 | 2801 |
2802 var h = { | 2802 var h = { |
2803 "content-type" : "application/json; charset=utf-8", | 2803 "content-type" : "application/json; charset=utf-8", |
2804 }; | 2804 }; |
2805 var resp = convert.JSON.encode(buildApksAddExternallyHostedResponse()); | 2805 var resp = convert.JSON.encode(buildApksAddExternallyHostedResponse()); |
2806 return new async.Future.value(stringResponse(200, h, resp)); | 2806 return new async.Future.value(stringResponse(200, h, resp)); |
2807 }), true); | 2807 }), true); |
2808 res.addexternallyhosted(arg_request, arg_packageName, arg_editId).then(uni
ttest.expectAsync(((api.ApksAddExternallyHostedResponse response) { | 2808 res.addexternallyhosted(arg_request, arg_packageName, arg_editId).then(uni
ttest.expectAsync1(((api.ApksAddExternallyHostedResponse response) { |
2809 checkApksAddExternallyHostedResponse(response); | 2809 checkApksAddExternallyHostedResponse(response); |
2810 }))); | 2810 }))); |
2811 }); | 2811 }); |
2812 | 2812 |
2813 unittest.test("method--list", () { | 2813 unittest.test("method--list", () { |
2814 | 2814 |
2815 var mock = new HttpServerMock(); | 2815 var mock = new HttpServerMock(); |
2816 api.EditsApksResourceApi res = new api.AndroidpublisherApi(mock).edits.apk
s; | 2816 api.EditsApksResourceApi res = new api.AndroidpublisherApi(mock).edits.apk
s; |
2817 var arg_packageName = "foo"; | 2817 var arg_packageName = "foo"; |
2818 var arg_editId = "foo"; | 2818 var arg_editId = "foo"; |
2819 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2819 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2820 var path = (req.url).path; | 2820 var path = (req.url).path; |
2821 var pathOffset = 0; | 2821 var pathOffset = 0; |
2822 var index; | 2822 var index; |
2823 var subPart; | 2823 var subPart; |
2824 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2824 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2825 pathOffset += 1; | 2825 pathOffset += 1; |
2826 | 2826 |
2827 var query = (req.url).query; | 2827 var query = (req.url).query; |
2828 var queryOffset = 0; | 2828 var queryOffset = 0; |
2829 var queryMap = {}; | 2829 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
2841 } | 2841 } |
2842 } | 2842 } |
2843 | 2843 |
2844 | 2844 |
2845 var h = { | 2845 var h = { |
2846 "content-type" : "application/json; charset=utf-8", | 2846 "content-type" : "application/json; charset=utf-8", |
2847 }; | 2847 }; |
2848 var resp = convert.JSON.encode(buildApksListResponse()); | 2848 var resp = convert.JSON.encode(buildApksListResponse()); |
2849 return new async.Future.value(stringResponse(200, h, resp)); | 2849 return new async.Future.value(stringResponse(200, h, resp)); |
2850 }), true); | 2850 }), true); |
2851 res.list(arg_packageName, arg_editId).then(unittest.expectAsync(((api.Apks
ListResponse response) { | 2851 res.list(arg_packageName, arg_editId).then(unittest.expectAsync1(((api.Apk
sListResponse response) { |
2852 checkApksListResponse(response); | 2852 checkApksListResponse(response); |
2853 }))); | 2853 }))); |
2854 }); | 2854 }); |
2855 | 2855 |
2856 unittest.test("method--upload", () { | 2856 unittest.test("method--upload", () { |
2857 // TODO: Implement tests for media upload; | 2857 // TODO: Implement tests for media upload; |
2858 // TODO: Implement tests for media download; | 2858 // TODO: Implement tests for media download; |
2859 | 2859 |
2860 var mock = new HttpServerMock(); | 2860 var mock = new HttpServerMock(); |
2861 api.EditsApksResourceApi res = new api.AndroidpublisherApi(mock).edits.apk
s; | 2861 api.EditsApksResourceApi res = new api.AndroidpublisherApi(mock).edits.apk
s; |
2862 var arg_packageName = "foo"; | 2862 var arg_packageName = "foo"; |
2863 var arg_editId = "foo"; | 2863 var arg_editId = "foo"; |
2864 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2864 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2865 var path = (req.url).path; | 2865 var path = (req.url).path; |
2866 var pathOffset = 0; | 2866 var pathOffset = 0; |
2867 var index; | 2867 var index; |
2868 var subPart; | 2868 var subPart; |
2869 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2869 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2870 pathOffset += 1; | 2870 pathOffset += 1; |
2871 | 2871 |
2872 var query = (req.url).query; | 2872 var query = (req.url).query; |
2873 var queryOffset = 0; | 2873 var queryOffset = 0; |
2874 var queryMap = {}; | 2874 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
2886 } | 2886 } |
2887 } | 2887 } |
2888 | 2888 |
2889 | 2889 |
2890 var h = { | 2890 var h = { |
2891 "content-type" : "application/json; charset=utf-8", | 2891 "content-type" : "application/json; charset=utf-8", |
2892 }; | 2892 }; |
2893 var resp = convert.JSON.encode(buildApk()); | 2893 var resp = convert.JSON.encode(buildApk()); |
2894 return new async.Future.value(stringResponse(200, h, resp)); | 2894 return new async.Future.value(stringResponse(200, h, resp)); |
2895 }), true); | 2895 }), true); |
2896 res.upload(arg_packageName, arg_editId).then(unittest.expectAsync(((api.Ap
k response) { | 2896 res.upload(arg_packageName, arg_editId).then(unittest.expectAsync1(((api.A
pk response) { |
2897 checkApk(response); | 2897 checkApk(response); |
2898 }))); | 2898 }))); |
2899 }); | 2899 }); |
2900 | 2900 |
2901 }); | 2901 }); |
2902 | 2902 |
2903 | 2903 |
2904 unittest.group("resource-EditsDeobfuscationfilesResourceApi", () { | 2904 unittest.group("resource-EditsDeobfuscationfilesResourceApi", () { |
2905 unittest.test("method--upload", () { | 2905 unittest.test("method--upload", () { |
2906 // TODO: Implement tests for media upload; | 2906 // TODO: Implement tests for media upload; |
2907 // TODO: Implement tests for media download; | 2907 // TODO: Implement tests for media download; |
2908 | 2908 |
2909 var mock = new HttpServerMock(); | 2909 var mock = new HttpServerMock(); |
2910 api.EditsDeobfuscationfilesResourceApi res = new api.AndroidpublisherApi(m
ock).edits.deobfuscationfiles; | 2910 api.EditsDeobfuscationfilesResourceApi res = new api.AndroidpublisherApi(m
ock).edits.deobfuscationfiles; |
2911 var arg_packageName = "foo"; | 2911 var arg_packageName = "foo"; |
2912 var arg_editId = "foo"; | 2912 var arg_editId = "foo"; |
2913 var arg_apkVersionCode = 42; | 2913 var arg_apkVersionCode = 42; |
2914 var arg_deobfuscationFileType = "foo"; | 2914 var arg_deobfuscationFileType = "foo"; |
2915 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2915 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2916 var path = (req.url).path; | 2916 var path = (req.url).path; |
2917 var pathOffset = 0; | 2917 var pathOffset = 0; |
2918 var index; | 2918 var index; |
2919 var subPart; | 2919 var subPart; |
2920 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2920 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2921 pathOffset += 1; | 2921 pathOffset += 1; |
2922 | 2922 |
2923 var query = (req.url).query; | 2923 var query = (req.url).query; |
2924 var queryOffset = 0; | 2924 var queryOffset = 0; |
2925 var queryMap = {}; | 2925 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
2937 } | 2937 } |
2938 } | 2938 } |
2939 | 2939 |
2940 | 2940 |
2941 var h = { | 2941 var h = { |
2942 "content-type" : "application/json; charset=utf-8", | 2942 "content-type" : "application/json; charset=utf-8", |
2943 }; | 2943 }; |
2944 var resp = convert.JSON.encode(buildDeobfuscationFilesUploadResponse()); | 2944 var resp = convert.JSON.encode(buildDeobfuscationFilesUploadResponse()); |
2945 return new async.Future.value(stringResponse(200, h, resp)); | 2945 return new async.Future.value(stringResponse(200, h, resp)); |
2946 }), true); | 2946 }), true); |
2947 res.upload(arg_packageName, arg_editId, arg_apkVersionCode, arg_deobfuscat
ionFileType).then(unittest.expectAsync(((api.DeobfuscationFilesUploadResponse re
sponse) { | 2947 res.upload(arg_packageName, arg_editId, arg_apkVersionCode, arg_deobfuscat
ionFileType).then(unittest.expectAsync1(((api.DeobfuscationFilesUploadResponse r
esponse) { |
2948 checkDeobfuscationFilesUploadResponse(response); | 2948 checkDeobfuscationFilesUploadResponse(response); |
2949 }))); | 2949 }))); |
2950 }); | 2950 }); |
2951 | 2951 |
2952 }); | 2952 }); |
2953 | 2953 |
2954 | 2954 |
2955 unittest.group("resource-EditsDetailsResourceApi", () { | 2955 unittest.group("resource-EditsDetailsResourceApi", () { |
2956 unittest.test("method--get", () { | 2956 unittest.test("method--get", () { |
2957 | 2957 |
2958 var mock = new HttpServerMock(); | 2958 var mock = new HttpServerMock(); |
2959 api.EditsDetailsResourceApi res = new api.AndroidpublisherApi(mock).edits.
details; | 2959 api.EditsDetailsResourceApi res = new api.AndroidpublisherApi(mock).edits.
details; |
2960 var arg_packageName = "foo"; | 2960 var arg_packageName = "foo"; |
2961 var arg_editId = "foo"; | 2961 var arg_editId = "foo"; |
2962 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2962 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2963 var path = (req.url).path; | 2963 var path = (req.url).path; |
2964 var pathOffset = 0; | 2964 var pathOffset = 0; |
2965 var index; | 2965 var index; |
2966 var subPart; | 2966 var subPart; |
2967 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2967 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2968 pathOffset += 1; | 2968 pathOffset += 1; |
2969 | 2969 |
2970 var query = (req.url).query; | 2970 var query = (req.url).query; |
2971 var queryOffset = 0; | 2971 var queryOffset = 0; |
2972 var queryMap = {}; | 2972 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
2984 } | 2984 } |
2985 } | 2985 } |
2986 | 2986 |
2987 | 2987 |
2988 var h = { | 2988 var h = { |
2989 "content-type" : "application/json; charset=utf-8", | 2989 "content-type" : "application/json; charset=utf-8", |
2990 }; | 2990 }; |
2991 var resp = convert.JSON.encode(buildAppDetails()); | 2991 var resp = convert.JSON.encode(buildAppDetails()); |
2992 return new async.Future.value(stringResponse(200, h, resp)); | 2992 return new async.Future.value(stringResponse(200, h, resp)); |
2993 }), true); | 2993 }), true); |
2994 res.get(arg_packageName, arg_editId).then(unittest.expectAsync(((api.AppDe
tails response) { | 2994 res.get(arg_packageName, arg_editId).then(unittest.expectAsync1(((api.AppD
etails response) { |
2995 checkAppDetails(response); | 2995 checkAppDetails(response); |
2996 }))); | 2996 }))); |
2997 }); | 2997 }); |
2998 | 2998 |
2999 unittest.test("method--patch", () { | 2999 unittest.test("method--patch", () { |
3000 | 3000 |
3001 var mock = new HttpServerMock(); | 3001 var mock = new HttpServerMock(); |
3002 api.EditsDetailsResourceApi res = new api.AndroidpublisherApi(mock).edits.
details; | 3002 api.EditsDetailsResourceApi res = new api.AndroidpublisherApi(mock).edits.
details; |
3003 var arg_request = buildAppDetails(); | 3003 var arg_request = buildAppDetails(); |
3004 var arg_packageName = "foo"; | 3004 var arg_packageName = "foo"; |
3005 var arg_editId = "foo"; | 3005 var arg_editId = "foo"; |
3006 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3006 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3007 var obj = new api.AppDetails.fromJson(json); | 3007 var obj = new api.AppDetails.fromJson(json); |
3008 checkAppDetails(obj); | 3008 checkAppDetails(obj); |
3009 | 3009 |
3010 var path = (req.url).path; | 3010 var path = (req.url).path; |
3011 var pathOffset = 0; | 3011 var pathOffset = 0; |
3012 var index; | 3012 var index; |
3013 var subPart; | 3013 var subPart; |
3014 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3014 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3015 pathOffset += 1; | 3015 pathOffset += 1; |
3016 | 3016 |
(...skipping 14 matching lines...) Expand all Loading... |
3031 } | 3031 } |
3032 } | 3032 } |
3033 | 3033 |
3034 | 3034 |
3035 var h = { | 3035 var h = { |
3036 "content-type" : "application/json; charset=utf-8", | 3036 "content-type" : "application/json; charset=utf-8", |
3037 }; | 3037 }; |
3038 var resp = convert.JSON.encode(buildAppDetails()); | 3038 var resp = convert.JSON.encode(buildAppDetails()); |
3039 return new async.Future.value(stringResponse(200, h, resp)); | 3039 return new async.Future.value(stringResponse(200, h, resp)); |
3040 }), true); | 3040 }), true); |
3041 res.patch(arg_request, arg_packageName, arg_editId).then(unittest.expectAs
ync(((api.AppDetails response) { | 3041 res.patch(arg_request, arg_packageName, arg_editId).then(unittest.expectAs
ync1(((api.AppDetails response) { |
3042 checkAppDetails(response); | 3042 checkAppDetails(response); |
3043 }))); | 3043 }))); |
3044 }); | 3044 }); |
3045 | 3045 |
3046 unittest.test("method--update", () { | 3046 unittest.test("method--update", () { |
3047 | 3047 |
3048 var mock = new HttpServerMock(); | 3048 var mock = new HttpServerMock(); |
3049 api.EditsDetailsResourceApi res = new api.AndroidpublisherApi(mock).edits.
details; | 3049 api.EditsDetailsResourceApi res = new api.AndroidpublisherApi(mock).edits.
details; |
3050 var arg_request = buildAppDetails(); | 3050 var arg_request = buildAppDetails(); |
3051 var arg_packageName = "foo"; | 3051 var arg_packageName = "foo"; |
3052 var arg_editId = "foo"; | 3052 var arg_editId = "foo"; |
3053 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3053 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3054 var obj = new api.AppDetails.fromJson(json); | 3054 var obj = new api.AppDetails.fromJson(json); |
3055 checkAppDetails(obj); | 3055 checkAppDetails(obj); |
3056 | 3056 |
3057 var path = (req.url).path; | 3057 var path = (req.url).path; |
3058 var pathOffset = 0; | 3058 var pathOffset = 0; |
3059 var index; | 3059 var index; |
3060 var subPart; | 3060 var subPart; |
3061 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3061 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3062 pathOffset += 1; | 3062 pathOffset += 1; |
3063 | 3063 |
(...skipping 14 matching lines...) Expand all Loading... |
3078 } | 3078 } |
3079 } | 3079 } |
3080 | 3080 |
3081 | 3081 |
3082 var h = { | 3082 var h = { |
3083 "content-type" : "application/json; charset=utf-8", | 3083 "content-type" : "application/json; charset=utf-8", |
3084 }; | 3084 }; |
3085 var resp = convert.JSON.encode(buildAppDetails()); | 3085 var resp = convert.JSON.encode(buildAppDetails()); |
3086 return new async.Future.value(stringResponse(200, h, resp)); | 3086 return new async.Future.value(stringResponse(200, h, resp)); |
3087 }), true); | 3087 }), true); |
3088 res.update(arg_request, arg_packageName, arg_editId).then(unittest.expectA
sync(((api.AppDetails response) { | 3088 res.update(arg_request, arg_packageName, arg_editId).then(unittest.expectA
sync1(((api.AppDetails response) { |
3089 checkAppDetails(response); | 3089 checkAppDetails(response); |
3090 }))); | 3090 }))); |
3091 }); | 3091 }); |
3092 | 3092 |
3093 }); | 3093 }); |
3094 | 3094 |
3095 | 3095 |
3096 unittest.group("resource-EditsExpansionfilesResourceApi", () { | 3096 unittest.group("resource-EditsExpansionfilesResourceApi", () { |
3097 unittest.test("method--get", () { | 3097 unittest.test("method--get", () { |
3098 | 3098 |
3099 var mock = new HttpServerMock(); | 3099 var mock = new HttpServerMock(); |
3100 api.EditsExpansionfilesResourceApi res = new api.AndroidpublisherApi(mock)
.edits.expansionfiles; | 3100 api.EditsExpansionfilesResourceApi res = new api.AndroidpublisherApi(mock)
.edits.expansionfiles; |
3101 var arg_packageName = "foo"; | 3101 var arg_packageName = "foo"; |
3102 var arg_editId = "foo"; | 3102 var arg_editId = "foo"; |
3103 var arg_apkVersionCode = 42; | 3103 var arg_apkVersionCode = 42; |
3104 var arg_expansionFileType = "foo"; | 3104 var arg_expansionFileType = "foo"; |
3105 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3105 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3106 var path = (req.url).path; | 3106 var path = (req.url).path; |
3107 var pathOffset = 0; | 3107 var pathOffset = 0; |
3108 var index; | 3108 var index; |
3109 var subPart; | 3109 var subPart; |
3110 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3110 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3111 pathOffset += 1; | 3111 pathOffset += 1; |
3112 | 3112 |
3113 var query = (req.url).query; | 3113 var query = (req.url).query; |
3114 var queryOffset = 0; | 3114 var queryOffset = 0; |
3115 var queryMap = {}; | 3115 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
3127 } | 3127 } |
3128 } | 3128 } |
3129 | 3129 |
3130 | 3130 |
3131 var h = { | 3131 var h = { |
3132 "content-type" : "application/json; charset=utf-8", | 3132 "content-type" : "application/json; charset=utf-8", |
3133 }; | 3133 }; |
3134 var resp = convert.JSON.encode(buildExpansionFile()); | 3134 var resp = convert.JSON.encode(buildExpansionFile()); |
3135 return new async.Future.value(stringResponse(200, h, resp)); | 3135 return new async.Future.value(stringResponse(200, h, resp)); |
3136 }), true); | 3136 }), true); |
3137 res.get(arg_packageName, arg_editId, arg_apkVersionCode, arg_expansionFile
Type).then(unittest.expectAsync(((api.ExpansionFile response) { | 3137 res.get(arg_packageName, arg_editId, arg_apkVersionCode, arg_expansionFile
Type).then(unittest.expectAsync1(((api.ExpansionFile response) { |
3138 checkExpansionFile(response); | 3138 checkExpansionFile(response); |
3139 }))); | 3139 }))); |
3140 }); | 3140 }); |
3141 | 3141 |
3142 unittest.test("method--patch", () { | 3142 unittest.test("method--patch", () { |
3143 | 3143 |
3144 var mock = new HttpServerMock(); | 3144 var mock = new HttpServerMock(); |
3145 api.EditsExpansionfilesResourceApi res = new api.AndroidpublisherApi(mock)
.edits.expansionfiles; | 3145 api.EditsExpansionfilesResourceApi res = new api.AndroidpublisherApi(mock)
.edits.expansionfiles; |
3146 var arg_request = buildExpansionFile(); | 3146 var arg_request = buildExpansionFile(); |
3147 var arg_packageName = "foo"; | 3147 var arg_packageName = "foo"; |
3148 var arg_editId = "foo"; | 3148 var arg_editId = "foo"; |
3149 var arg_apkVersionCode = 42; | 3149 var arg_apkVersionCode = 42; |
3150 var arg_expansionFileType = "foo"; | 3150 var arg_expansionFileType = "foo"; |
3151 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3151 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3152 var obj = new api.ExpansionFile.fromJson(json); | 3152 var obj = new api.ExpansionFile.fromJson(json); |
3153 checkExpansionFile(obj); | 3153 checkExpansionFile(obj); |
3154 | 3154 |
3155 var path = (req.url).path; | 3155 var path = (req.url).path; |
3156 var pathOffset = 0; | 3156 var pathOffset = 0; |
3157 var index; | 3157 var index; |
3158 var subPart; | 3158 var subPart; |
3159 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3159 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3160 pathOffset += 1; | 3160 pathOffset += 1; |
3161 | 3161 |
(...skipping 14 matching lines...) Expand all Loading... |
3176 } | 3176 } |
3177 } | 3177 } |
3178 | 3178 |
3179 | 3179 |
3180 var h = { | 3180 var h = { |
3181 "content-type" : "application/json; charset=utf-8", | 3181 "content-type" : "application/json; charset=utf-8", |
3182 }; | 3182 }; |
3183 var resp = convert.JSON.encode(buildExpansionFile()); | 3183 var resp = convert.JSON.encode(buildExpansionFile()); |
3184 return new async.Future.value(stringResponse(200, h, resp)); | 3184 return new async.Future.value(stringResponse(200, h, resp)); |
3185 }), true); | 3185 }), true); |
3186 res.patch(arg_request, arg_packageName, arg_editId, arg_apkVersionCode, ar
g_expansionFileType).then(unittest.expectAsync(((api.ExpansionFile response) { | 3186 res.patch(arg_request, arg_packageName, arg_editId, arg_apkVersionCode, ar
g_expansionFileType).then(unittest.expectAsync1(((api.ExpansionFile response) { |
3187 checkExpansionFile(response); | 3187 checkExpansionFile(response); |
3188 }))); | 3188 }))); |
3189 }); | 3189 }); |
3190 | 3190 |
3191 unittest.test("method--update", () { | 3191 unittest.test("method--update", () { |
3192 | 3192 |
3193 var mock = new HttpServerMock(); | 3193 var mock = new HttpServerMock(); |
3194 api.EditsExpansionfilesResourceApi res = new api.AndroidpublisherApi(mock)
.edits.expansionfiles; | 3194 api.EditsExpansionfilesResourceApi res = new api.AndroidpublisherApi(mock)
.edits.expansionfiles; |
3195 var arg_request = buildExpansionFile(); | 3195 var arg_request = buildExpansionFile(); |
3196 var arg_packageName = "foo"; | 3196 var arg_packageName = "foo"; |
3197 var arg_editId = "foo"; | 3197 var arg_editId = "foo"; |
3198 var arg_apkVersionCode = 42; | 3198 var arg_apkVersionCode = 42; |
3199 var arg_expansionFileType = "foo"; | 3199 var arg_expansionFileType = "foo"; |
3200 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3200 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3201 var obj = new api.ExpansionFile.fromJson(json); | 3201 var obj = new api.ExpansionFile.fromJson(json); |
3202 checkExpansionFile(obj); | 3202 checkExpansionFile(obj); |
3203 | 3203 |
3204 var path = (req.url).path; | 3204 var path = (req.url).path; |
3205 var pathOffset = 0; | 3205 var pathOffset = 0; |
3206 var index; | 3206 var index; |
3207 var subPart; | 3207 var subPart; |
3208 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3208 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3209 pathOffset += 1; | 3209 pathOffset += 1; |
3210 | 3210 |
(...skipping 14 matching lines...) Expand all Loading... |
3225 } | 3225 } |
3226 } | 3226 } |
3227 | 3227 |
3228 | 3228 |
3229 var h = { | 3229 var h = { |
3230 "content-type" : "application/json; charset=utf-8", | 3230 "content-type" : "application/json; charset=utf-8", |
3231 }; | 3231 }; |
3232 var resp = convert.JSON.encode(buildExpansionFile()); | 3232 var resp = convert.JSON.encode(buildExpansionFile()); |
3233 return new async.Future.value(stringResponse(200, h, resp)); | 3233 return new async.Future.value(stringResponse(200, h, resp)); |
3234 }), true); | 3234 }), true); |
3235 res.update(arg_request, arg_packageName, arg_editId, arg_apkVersionCode, a
rg_expansionFileType).then(unittest.expectAsync(((api.ExpansionFile response) { | 3235 res.update(arg_request, arg_packageName, arg_editId, arg_apkVersionCode, a
rg_expansionFileType).then(unittest.expectAsync1(((api.ExpansionFile response) { |
3236 checkExpansionFile(response); | 3236 checkExpansionFile(response); |
3237 }))); | 3237 }))); |
3238 }); | 3238 }); |
3239 | 3239 |
3240 unittest.test("method--upload", () { | 3240 unittest.test("method--upload", () { |
3241 // TODO: Implement tests for media upload; | 3241 // TODO: Implement tests for media upload; |
3242 // TODO: Implement tests for media download; | 3242 // TODO: Implement tests for media download; |
3243 | 3243 |
3244 var mock = new HttpServerMock(); | 3244 var mock = new HttpServerMock(); |
3245 api.EditsExpansionfilesResourceApi res = new api.AndroidpublisherApi(mock)
.edits.expansionfiles; | 3245 api.EditsExpansionfilesResourceApi res = new api.AndroidpublisherApi(mock)
.edits.expansionfiles; |
3246 var arg_packageName = "foo"; | 3246 var arg_packageName = "foo"; |
3247 var arg_editId = "foo"; | 3247 var arg_editId = "foo"; |
3248 var arg_apkVersionCode = 42; | 3248 var arg_apkVersionCode = 42; |
3249 var arg_expansionFileType = "foo"; | 3249 var arg_expansionFileType = "foo"; |
3250 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3250 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3251 var path = (req.url).path; | 3251 var path = (req.url).path; |
3252 var pathOffset = 0; | 3252 var pathOffset = 0; |
3253 var index; | 3253 var index; |
3254 var subPart; | 3254 var subPart; |
3255 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3255 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3256 pathOffset += 1; | 3256 pathOffset += 1; |
3257 | 3257 |
3258 var query = (req.url).query; | 3258 var query = (req.url).query; |
3259 var queryOffset = 0; | 3259 var queryOffset = 0; |
3260 var queryMap = {}; | 3260 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
3272 } | 3272 } |
3273 } | 3273 } |
3274 | 3274 |
3275 | 3275 |
3276 var h = { | 3276 var h = { |
3277 "content-type" : "application/json; charset=utf-8", | 3277 "content-type" : "application/json; charset=utf-8", |
3278 }; | 3278 }; |
3279 var resp = convert.JSON.encode(buildExpansionFilesUploadResponse()); | 3279 var resp = convert.JSON.encode(buildExpansionFilesUploadResponse()); |
3280 return new async.Future.value(stringResponse(200, h, resp)); | 3280 return new async.Future.value(stringResponse(200, h, resp)); |
3281 }), true); | 3281 }), true); |
3282 res.upload(arg_packageName, arg_editId, arg_apkVersionCode, arg_expansionF
ileType).then(unittest.expectAsync(((api.ExpansionFilesUploadResponse response)
{ | 3282 res.upload(arg_packageName, arg_editId, arg_apkVersionCode, arg_expansionF
ileType).then(unittest.expectAsync1(((api.ExpansionFilesUploadResponse response)
{ |
3283 checkExpansionFilesUploadResponse(response); | 3283 checkExpansionFilesUploadResponse(response); |
3284 }))); | 3284 }))); |
3285 }); | 3285 }); |
3286 | 3286 |
3287 }); | 3287 }); |
3288 | 3288 |
3289 | 3289 |
3290 unittest.group("resource-EditsImagesResourceApi", () { | 3290 unittest.group("resource-EditsImagesResourceApi", () { |
3291 unittest.test("method--delete", () { | 3291 unittest.test("method--delete", () { |
3292 | 3292 |
3293 var mock = new HttpServerMock(); | 3293 var mock = new HttpServerMock(); |
3294 api.EditsImagesResourceApi res = new api.AndroidpublisherApi(mock).edits.i
mages; | 3294 api.EditsImagesResourceApi res = new api.AndroidpublisherApi(mock).edits.i
mages; |
3295 var arg_packageName = "foo"; | 3295 var arg_packageName = "foo"; |
3296 var arg_editId = "foo"; | 3296 var arg_editId = "foo"; |
3297 var arg_language = "foo"; | 3297 var arg_language = "foo"; |
3298 var arg_imageType = "foo"; | 3298 var arg_imageType = "foo"; |
3299 var arg_imageId = "foo"; | 3299 var arg_imageId = "foo"; |
3300 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3300 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3301 var path = (req.url).path; | 3301 var path = (req.url).path; |
3302 var pathOffset = 0; | 3302 var pathOffset = 0; |
3303 var index; | 3303 var index; |
3304 var subPart; | 3304 var subPart; |
3305 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3305 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3306 pathOffset += 1; | 3306 pathOffset += 1; |
3307 | 3307 |
3308 var query = (req.url).query; | 3308 var query = (req.url).query; |
3309 var queryOffset = 0; | 3309 var queryOffset = 0; |
3310 var queryMap = {}; | 3310 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
3322 } | 3322 } |
3323 } | 3323 } |
3324 | 3324 |
3325 | 3325 |
3326 var h = { | 3326 var h = { |
3327 "content-type" : "application/json; charset=utf-8", | 3327 "content-type" : "application/json; charset=utf-8", |
3328 }; | 3328 }; |
3329 var resp = ""; | 3329 var resp = ""; |
3330 return new async.Future.value(stringResponse(200, h, resp)); | 3330 return new async.Future.value(stringResponse(200, h, resp)); |
3331 }), true); | 3331 }), true); |
3332 res.delete(arg_packageName, arg_editId, arg_language, arg_imageType, arg_i
mageId).then(unittest.expectAsync((_) {})); | 3332 res.delete(arg_packageName, arg_editId, arg_language, arg_imageType, arg_i
mageId).then(unittest.expectAsync1((_) {})); |
3333 }); | 3333 }); |
3334 | 3334 |
3335 unittest.test("method--deleteall", () { | 3335 unittest.test("method--deleteall", () { |
3336 | 3336 |
3337 var mock = new HttpServerMock(); | 3337 var mock = new HttpServerMock(); |
3338 api.EditsImagesResourceApi res = new api.AndroidpublisherApi(mock).edits.i
mages; | 3338 api.EditsImagesResourceApi res = new api.AndroidpublisherApi(mock).edits.i
mages; |
3339 var arg_packageName = "foo"; | 3339 var arg_packageName = "foo"; |
3340 var arg_editId = "foo"; | 3340 var arg_editId = "foo"; |
3341 var arg_language = "foo"; | 3341 var arg_language = "foo"; |
3342 var arg_imageType = "foo"; | 3342 var arg_imageType = "foo"; |
3343 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3343 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3344 var path = (req.url).path; | 3344 var path = (req.url).path; |
3345 var pathOffset = 0; | 3345 var pathOffset = 0; |
3346 var index; | 3346 var index; |
3347 var subPart; | 3347 var subPart; |
3348 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3348 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3349 pathOffset += 1; | 3349 pathOffset += 1; |
3350 | 3350 |
3351 var query = (req.url).query; | 3351 var query = (req.url).query; |
3352 var queryOffset = 0; | 3352 var queryOffset = 0; |
3353 var queryMap = {}; | 3353 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
3365 } | 3365 } |
3366 } | 3366 } |
3367 | 3367 |
3368 | 3368 |
3369 var h = { | 3369 var h = { |
3370 "content-type" : "application/json; charset=utf-8", | 3370 "content-type" : "application/json; charset=utf-8", |
3371 }; | 3371 }; |
3372 var resp = convert.JSON.encode(buildImagesDeleteAllResponse()); | 3372 var resp = convert.JSON.encode(buildImagesDeleteAllResponse()); |
3373 return new async.Future.value(stringResponse(200, h, resp)); | 3373 return new async.Future.value(stringResponse(200, h, resp)); |
3374 }), true); | 3374 }), true); |
3375 res.deleteall(arg_packageName, arg_editId, arg_language, arg_imageType).th
en(unittest.expectAsync(((api.ImagesDeleteAllResponse response) { | 3375 res.deleteall(arg_packageName, arg_editId, arg_language, arg_imageType).th
en(unittest.expectAsync1(((api.ImagesDeleteAllResponse response) { |
3376 checkImagesDeleteAllResponse(response); | 3376 checkImagesDeleteAllResponse(response); |
3377 }))); | 3377 }))); |
3378 }); | 3378 }); |
3379 | 3379 |
3380 unittest.test("method--list", () { | 3380 unittest.test("method--list", () { |
3381 | 3381 |
3382 var mock = new HttpServerMock(); | 3382 var mock = new HttpServerMock(); |
3383 api.EditsImagesResourceApi res = new api.AndroidpublisherApi(mock).edits.i
mages; | 3383 api.EditsImagesResourceApi res = new api.AndroidpublisherApi(mock).edits.i
mages; |
3384 var arg_packageName = "foo"; | 3384 var arg_packageName = "foo"; |
3385 var arg_editId = "foo"; | 3385 var arg_editId = "foo"; |
3386 var arg_language = "foo"; | 3386 var arg_language = "foo"; |
3387 var arg_imageType = "foo"; | 3387 var arg_imageType = "foo"; |
3388 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3388 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3389 var path = (req.url).path; | 3389 var path = (req.url).path; |
3390 var pathOffset = 0; | 3390 var pathOffset = 0; |
3391 var index; | 3391 var index; |
3392 var subPart; | 3392 var subPart; |
3393 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3393 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3394 pathOffset += 1; | 3394 pathOffset += 1; |
3395 | 3395 |
3396 var query = (req.url).query; | 3396 var query = (req.url).query; |
3397 var queryOffset = 0; | 3397 var queryOffset = 0; |
3398 var queryMap = {}; | 3398 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
3410 } | 3410 } |
3411 } | 3411 } |
3412 | 3412 |
3413 | 3413 |
3414 var h = { | 3414 var h = { |
3415 "content-type" : "application/json; charset=utf-8", | 3415 "content-type" : "application/json; charset=utf-8", |
3416 }; | 3416 }; |
3417 var resp = convert.JSON.encode(buildImagesListResponse()); | 3417 var resp = convert.JSON.encode(buildImagesListResponse()); |
3418 return new async.Future.value(stringResponse(200, h, resp)); | 3418 return new async.Future.value(stringResponse(200, h, resp)); |
3419 }), true); | 3419 }), true); |
3420 res.list(arg_packageName, arg_editId, arg_language, arg_imageType).then(un
ittest.expectAsync(((api.ImagesListResponse response) { | 3420 res.list(arg_packageName, arg_editId, arg_language, arg_imageType).then(un
ittest.expectAsync1(((api.ImagesListResponse response) { |
3421 checkImagesListResponse(response); | 3421 checkImagesListResponse(response); |
3422 }))); | 3422 }))); |
3423 }); | 3423 }); |
3424 | 3424 |
3425 unittest.test("method--upload", () { | 3425 unittest.test("method--upload", () { |
3426 // TODO: Implement tests for media upload; | 3426 // TODO: Implement tests for media upload; |
3427 // TODO: Implement tests for media download; | 3427 // TODO: Implement tests for media download; |
3428 | 3428 |
3429 var mock = new HttpServerMock(); | 3429 var mock = new HttpServerMock(); |
3430 api.EditsImagesResourceApi res = new api.AndroidpublisherApi(mock).edits.i
mages; | 3430 api.EditsImagesResourceApi res = new api.AndroidpublisherApi(mock).edits.i
mages; |
3431 var arg_packageName = "foo"; | 3431 var arg_packageName = "foo"; |
3432 var arg_editId = "foo"; | 3432 var arg_editId = "foo"; |
3433 var arg_language = "foo"; | 3433 var arg_language = "foo"; |
3434 var arg_imageType = "foo"; | 3434 var arg_imageType = "foo"; |
3435 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3435 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3436 var path = (req.url).path; | 3436 var path = (req.url).path; |
3437 var pathOffset = 0; | 3437 var pathOffset = 0; |
3438 var index; | 3438 var index; |
3439 var subPart; | 3439 var subPart; |
3440 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3440 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3441 pathOffset += 1; | 3441 pathOffset += 1; |
3442 | 3442 |
3443 var query = (req.url).query; | 3443 var query = (req.url).query; |
3444 var queryOffset = 0; | 3444 var queryOffset = 0; |
3445 var queryMap = {}; | 3445 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
3457 } | 3457 } |
3458 } | 3458 } |
3459 | 3459 |
3460 | 3460 |
3461 var h = { | 3461 var h = { |
3462 "content-type" : "application/json; charset=utf-8", | 3462 "content-type" : "application/json; charset=utf-8", |
3463 }; | 3463 }; |
3464 var resp = convert.JSON.encode(buildImagesUploadResponse()); | 3464 var resp = convert.JSON.encode(buildImagesUploadResponse()); |
3465 return new async.Future.value(stringResponse(200, h, resp)); | 3465 return new async.Future.value(stringResponse(200, h, resp)); |
3466 }), true); | 3466 }), true); |
3467 res.upload(arg_packageName, arg_editId, arg_language, arg_imageType).then(
unittest.expectAsync(((api.ImagesUploadResponse response) { | 3467 res.upload(arg_packageName, arg_editId, arg_language, arg_imageType).then(
unittest.expectAsync1(((api.ImagesUploadResponse response) { |
3468 checkImagesUploadResponse(response); | 3468 checkImagesUploadResponse(response); |
3469 }))); | 3469 }))); |
3470 }); | 3470 }); |
3471 | 3471 |
3472 }); | 3472 }); |
3473 | 3473 |
3474 | 3474 |
3475 unittest.group("resource-EditsListingsResourceApi", () { | 3475 unittest.group("resource-EditsListingsResourceApi", () { |
3476 unittest.test("method--delete", () { | 3476 unittest.test("method--delete", () { |
3477 | 3477 |
3478 var mock = new HttpServerMock(); | 3478 var mock = new HttpServerMock(); |
3479 api.EditsListingsResourceApi res = new api.AndroidpublisherApi(mock).edits
.listings; | 3479 api.EditsListingsResourceApi res = new api.AndroidpublisherApi(mock).edits
.listings; |
3480 var arg_packageName = "foo"; | 3480 var arg_packageName = "foo"; |
3481 var arg_editId = "foo"; | 3481 var arg_editId = "foo"; |
3482 var arg_language = "foo"; | 3482 var arg_language = "foo"; |
3483 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3483 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3484 var path = (req.url).path; | 3484 var path = (req.url).path; |
3485 var pathOffset = 0; | 3485 var pathOffset = 0; |
3486 var index; | 3486 var index; |
3487 var subPart; | 3487 var subPart; |
3488 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3488 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3489 pathOffset += 1; | 3489 pathOffset += 1; |
3490 | 3490 |
3491 var query = (req.url).query; | 3491 var query = (req.url).query; |
3492 var queryOffset = 0; | 3492 var queryOffset = 0; |
3493 var queryMap = {}; | 3493 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
3505 } | 3505 } |
3506 } | 3506 } |
3507 | 3507 |
3508 | 3508 |
3509 var h = { | 3509 var h = { |
3510 "content-type" : "application/json; charset=utf-8", | 3510 "content-type" : "application/json; charset=utf-8", |
3511 }; | 3511 }; |
3512 var resp = ""; | 3512 var resp = ""; |
3513 return new async.Future.value(stringResponse(200, h, resp)); | 3513 return new async.Future.value(stringResponse(200, h, resp)); |
3514 }), true); | 3514 }), true); |
3515 res.delete(arg_packageName, arg_editId, arg_language).then(unittest.expect
Async((_) {})); | 3515 res.delete(arg_packageName, arg_editId, arg_language).then(unittest.expect
Async1((_) {})); |
3516 }); | 3516 }); |
3517 | 3517 |
3518 unittest.test("method--deleteall", () { | 3518 unittest.test("method--deleteall", () { |
3519 | 3519 |
3520 var mock = new HttpServerMock(); | 3520 var mock = new HttpServerMock(); |
3521 api.EditsListingsResourceApi res = new api.AndroidpublisherApi(mock).edits
.listings; | 3521 api.EditsListingsResourceApi res = new api.AndroidpublisherApi(mock).edits
.listings; |
3522 var arg_packageName = "foo"; | 3522 var arg_packageName = "foo"; |
3523 var arg_editId = "foo"; | 3523 var arg_editId = "foo"; |
3524 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3524 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3525 var path = (req.url).path; | 3525 var path = (req.url).path; |
3526 var pathOffset = 0; | 3526 var pathOffset = 0; |
3527 var index; | 3527 var index; |
3528 var subPart; | 3528 var subPart; |
3529 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3529 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3530 pathOffset += 1; | 3530 pathOffset += 1; |
3531 | 3531 |
3532 var query = (req.url).query; | 3532 var query = (req.url).query; |
3533 var queryOffset = 0; | 3533 var queryOffset = 0; |
3534 var queryMap = {}; | 3534 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
3546 } | 3546 } |
3547 } | 3547 } |
3548 | 3548 |
3549 | 3549 |
3550 var h = { | 3550 var h = { |
3551 "content-type" : "application/json; charset=utf-8", | 3551 "content-type" : "application/json; charset=utf-8", |
3552 }; | 3552 }; |
3553 var resp = ""; | 3553 var resp = ""; |
3554 return new async.Future.value(stringResponse(200, h, resp)); | 3554 return new async.Future.value(stringResponse(200, h, resp)); |
3555 }), true); | 3555 }), true); |
3556 res.deleteall(arg_packageName, arg_editId).then(unittest.expectAsync((_) {
})); | 3556 res.deleteall(arg_packageName, arg_editId).then(unittest.expectAsync1((_)
{})); |
3557 }); | 3557 }); |
3558 | 3558 |
3559 unittest.test("method--get", () { | 3559 unittest.test("method--get", () { |
3560 | 3560 |
3561 var mock = new HttpServerMock(); | 3561 var mock = new HttpServerMock(); |
3562 api.EditsListingsResourceApi res = new api.AndroidpublisherApi(mock).edits
.listings; | 3562 api.EditsListingsResourceApi res = new api.AndroidpublisherApi(mock).edits
.listings; |
3563 var arg_packageName = "foo"; | 3563 var arg_packageName = "foo"; |
3564 var arg_editId = "foo"; | 3564 var arg_editId = "foo"; |
3565 var arg_language = "foo"; | 3565 var arg_language = "foo"; |
3566 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3566 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3567 var path = (req.url).path; | 3567 var path = (req.url).path; |
3568 var pathOffset = 0; | 3568 var pathOffset = 0; |
3569 var index; | 3569 var index; |
3570 var subPart; | 3570 var subPart; |
3571 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3571 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3572 pathOffset += 1; | 3572 pathOffset += 1; |
3573 | 3573 |
3574 var query = (req.url).query; | 3574 var query = (req.url).query; |
3575 var queryOffset = 0; | 3575 var queryOffset = 0; |
3576 var queryMap = {}; | 3576 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
3588 } | 3588 } |
3589 } | 3589 } |
3590 | 3590 |
3591 | 3591 |
3592 var h = { | 3592 var h = { |
3593 "content-type" : "application/json; charset=utf-8", | 3593 "content-type" : "application/json; charset=utf-8", |
3594 }; | 3594 }; |
3595 var resp = convert.JSON.encode(buildListing()); | 3595 var resp = convert.JSON.encode(buildListing()); |
3596 return new async.Future.value(stringResponse(200, h, resp)); | 3596 return new async.Future.value(stringResponse(200, h, resp)); |
3597 }), true); | 3597 }), true); |
3598 res.get(arg_packageName, arg_editId, arg_language).then(unittest.expectAsy
nc(((api.Listing response) { | 3598 res.get(arg_packageName, arg_editId, arg_language).then(unittest.expectAsy
nc1(((api.Listing response) { |
3599 checkListing(response); | 3599 checkListing(response); |
3600 }))); | 3600 }))); |
3601 }); | 3601 }); |
3602 | 3602 |
3603 unittest.test("method--list", () { | 3603 unittest.test("method--list", () { |
3604 | 3604 |
3605 var mock = new HttpServerMock(); | 3605 var mock = new HttpServerMock(); |
3606 api.EditsListingsResourceApi res = new api.AndroidpublisherApi(mock).edits
.listings; | 3606 api.EditsListingsResourceApi res = new api.AndroidpublisherApi(mock).edits
.listings; |
3607 var arg_packageName = "foo"; | 3607 var arg_packageName = "foo"; |
3608 var arg_editId = "foo"; | 3608 var arg_editId = "foo"; |
3609 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3609 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3610 var path = (req.url).path; | 3610 var path = (req.url).path; |
3611 var pathOffset = 0; | 3611 var pathOffset = 0; |
3612 var index; | 3612 var index; |
3613 var subPart; | 3613 var subPart; |
3614 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3614 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3615 pathOffset += 1; | 3615 pathOffset += 1; |
3616 | 3616 |
3617 var query = (req.url).query; | 3617 var query = (req.url).query; |
3618 var queryOffset = 0; | 3618 var queryOffset = 0; |
3619 var queryMap = {}; | 3619 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
3631 } | 3631 } |
3632 } | 3632 } |
3633 | 3633 |
3634 | 3634 |
3635 var h = { | 3635 var h = { |
3636 "content-type" : "application/json; charset=utf-8", | 3636 "content-type" : "application/json; charset=utf-8", |
3637 }; | 3637 }; |
3638 var resp = convert.JSON.encode(buildListingsListResponse()); | 3638 var resp = convert.JSON.encode(buildListingsListResponse()); |
3639 return new async.Future.value(stringResponse(200, h, resp)); | 3639 return new async.Future.value(stringResponse(200, h, resp)); |
3640 }), true); | 3640 }), true); |
3641 res.list(arg_packageName, arg_editId).then(unittest.expectAsync(((api.List
ingsListResponse response) { | 3641 res.list(arg_packageName, arg_editId).then(unittest.expectAsync1(((api.Lis
tingsListResponse response) { |
3642 checkListingsListResponse(response); | 3642 checkListingsListResponse(response); |
3643 }))); | 3643 }))); |
3644 }); | 3644 }); |
3645 | 3645 |
3646 unittest.test("method--patch", () { | 3646 unittest.test("method--patch", () { |
3647 | 3647 |
3648 var mock = new HttpServerMock(); | 3648 var mock = new HttpServerMock(); |
3649 api.EditsListingsResourceApi res = new api.AndroidpublisherApi(mock).edits
.listings; | 3649 api.EditsListingsResourceApi res = new api.AndroidpublisherApi(mock).edits
.listings; |
3650 var arg_request = buildListing(); | 3650 var arg_request = buildListing(); |
3651 var arg_packageName = "foo"; | 3651 var arg_packageName = "foo"; |
3652 var arg_editId = "foo"; | 3652 var arg_editId = "foo"; |
3653 var arg_language = "foo"; | 3653 var arg_language = "foo"; |
3654 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3654 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3655 var obj = new api.Listing.fromJson(json); | 3655 var obj = new api.Listing.fromJson(json); |
3656 checkListing(obj); | 3656 checkListing(obj); |
3657 | 3657 |
3658 var path = (req.url).path; | 3658 var path = (req.url).path; |
3659 var pathOffset = 0; | 3659 var pathOffset = 0; |
3660 var index; | 3660 var index; |
3661 var subPart; | 3661 var subPart; |
3662 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3662 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3663 pathOffset += 1; | 3663 pathOffset += 1; |
3664 | 3664 |
(...skipping 14 matching lines...) Expand all Loading... |
3679 } | 3679 } |
3680 } | 3680 } |
3681 | 3681 |
3682 | 3682 |
3683 var h = { | 3683 var h = { |
3684 "content-type" : "application/json; charset=utf-8", | 3684 "content-type" : "application/json; charset=utf-8", |
3685 }; | 3685 }; |
3686 var resp = convert.JSON.encode(buildListing()); | 3686 var resp = convert.JSON.encode(buildListing()); |
3687 return new async.Future.value(stringResponse(200, h, resp)); | 3687 return new async.Future.value(stringResponse(200, h, resp)); |
3688 }), true); | 3688 }), true); |
3689 res.patch(arg_request, arg_packageName, arg_editId, arg_language).then(uni
ttest.expectAsync(((api.Listing response) { | 3689 res.patch(arg_request, arg_packageName, arg_editId, arg_language).then(uni
ttest.expectAsync1(((api.Listing response) { |
3690 checkListing(response); | 3690 checkListing(response); |
3691 }))); | 3691 }))); |
3692 }); | 3692 }); |
3693 | 3693 |
3694 unittest.test("method--update", () { | 3694 unittest.test("method--update", () { |
3695 | 3695 |
3696 var mock = new HttpServerMock(); | 3696 var mock = new HttpServerMock(); |
3697 api.EditsListingsResourceApi res = new api.AndroidpublisherApi(mock).edits
.listings; | 3697 api.EditsListingsResourceApi res = new api.AndroidpublisherApi(mock).edits
.listings; |
3698 var arg_request = buildListing(); | 3698 var arg_request = buildListing(); |
3699 var arg_packageName = "foo"; | 3699 var arg_packageName = "foo"; |
3700 var arg_editId = "foo"; | 3700 var arg_editId = "foo"; |
3701 var arg_language = "foo"; | 3701 var arg_language = "foo"; |
3702 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3702 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3703 var obj = new api.Listing.fromJson(json); | 3703 var obj = new api.Listing.fromJson(json); |
3704 checkListing(obj); | 3704 checkListing(obj); |
3705 | 3705 |
3706 var path = (req.url).path; | 3706 var path = (req.url).path; |
3707 var pathOffset = 0; | 3707 var pathOffset = 0; |
3708 var index; | 3708 var index; |
3709 var subPart; | 3709 var subPart; |
3710 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3710 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3711 pathOffset += 1; | 3711 pathOffset += 1; |
3712 | 3712 |
(...skipping 14 matching lines...) Expand all Loading... |
3727 } | 3727 } |
3728 } | 3728 } |
3729 | 3729 |
3730 | 3730 |
3731 var h = { | 3731 var h = { |
3732 "content-type" : "application/json; charset=utf-8", | 3732 "content-type" : "application/json; charset=utf-8", |
3733 }; | 3733 }; |
3734 var resp = convert.JSON.encode(buildListing()); | 3734 var resp = convert.JSON.encode(buildListing()); |
3735 return new async.Future.value(stringResponse(200, h, resp)); | 3735 return new async.Future.value(stringResponse(200, h, resp)); |
3736 }), true); | 3736 }), true); |
3737 res.update(arg_request, arg_packageName, arg_editId, arg_language).then(un
ittest.expectAsync(((api.Listing response) { | 3737 res.update(arg_request, arg_packageName, arg_editId, arg_language).then(un
ittest.expectAsync1(((api.Listing response) { |
3738 checkListing(response); | 3738 checkListing(response); |
3739 }))); | 3739 }))); |
3740 }); | 3740 }); |
3741 | 3741 |
3742 }); | 3742 }); |
3743 | 3743 |
3744 | 3744 |
3745 unittest.group("resource-EditsTestersResourceApi", () { | 3745 unittest.group("resource-EditsTestersResourceApi", () { |
3746 unittest.test("method--get", () { | 3746 unittest.test("method--get", () { |
3747 | 3747 |
3748 var mock = new HttpServerMock(); | 3748 var mock = new HttpServerMock(); |
3749 api.EditsTestersResourceApi res = new api.AndroidpublisherApi(mock).edits.
testers; | 3749 api.EditsTestersResourceApi res = new api.AndroidpublisherApi(mock).edits.
testers; |
3750 var arg_packageName = "foo"; | 3750 var arg_packageName = "foo"; |
3751 var arg_editId = "foo"; | 3751 var arg_editId = "foo"; |
3752 var arg_track = "foo"; | 3752 var arg_track = "foo"; |
3753 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3753 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3754 var path = (req.url).path; | 3754 var path = (req.url).path; |
3755 var pathOffset = 0; | 3755 var pathOffset = 0; |
3756 var index; | 3756 var index; |
3757 var subPart; | 3757 var subPart; |
3758 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3758 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3759 pathOffset += 1; | 3759 pathOffset += 1; |
3760 | 3760 |
3761 var query = (req.url).query; | 3761 var query = (req.url).query; |
3762 var queryOffset = 0; | 3762 var queryOffset = 0; |
3763 var queryMap = {}; | 3763 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
3775 } | 3775 } |
3776 } | 3776 } |
3777 | 3777 |
3778 | 3778 |
3779 var h = { | 3779 var h = { |
3780 "content-type" : "application/json; charset=utf-8", | 3780 "content-type" : "application/json; charset=utf-8", |
3781 }; | 3781 }; |
3782 var resp = convert.JSON.encode(buildTesters()); | 3782 var resp = convert.JSON.encode(buildTesters()); |
3783 return new async.Future.value(stringResponse(200, h, resp)); | 3783 return new async.Future.value(stringResponse(200, h, resp)); |
3784 }), true); | 3784 }), true); |
3785 res.get(arg_packageName, arg_editId, arg_track).then(unittest.expectAsync(
((api.Testers response) { | 3785 res.get(arg_packageName, arg_editId, arg_track).then(unittest.expectAsync1
(((api.Testers response) { |
3786 checkTesters(response); | 3786 checkTesters(response); |
3787 }))); | 3787 }))); |
3788 }); | 3788 }); |
3789 | 3789 |
3790 unittest.test("method--patch", () { | 3790 unittest.test("method--patch", () { |
3791 | 3791 |
3792 var mock = new HttpServerMock(); | 3792 var mock = new HttpServerMock(); |
3793 api.EditsTestersResourceApi res = new api.AndroidpublisherApi(mock).edits.
testers; | 3793 api.EditsTestersResourceApi res = new api.AndroidpublisherApi(mock).edits.
testers; |
3794 var arg_request = buildTesters(); | 3794 var arg_request = buildTesters(); |
3795 var arg_packageName = "foo"; | 3795 var arg_packageName = "foo"; |
3796 var arg_editId = "foo"; | 3796 var arg_editId = "foo"; |
3797 var arg_track = "foo"; | 3797 var arg_track = "foo"; |
3798 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3798 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3799 var obj = new api.Testers.fromJson(json); | 3799 var obj = new api.Testers.fromJson(json); |
3800 checkTesters(obj); | 3800 checkTesters(obj); |
3801 | 3801 |
3802 var path = (req.url).path; | 3802 var path = (req.url).path; |
3803 var pathOffset = 0; | 3803 var pathOffset = 0; |
3804 var index; | 3804 var index; |
3805 var subPart; | 3805 var subPart; |
3806 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3806 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3807 pathOffset += 1; | 3807 pathOffset += 1; |
3808 | 3808 |
(...skipping 14 matching lines...) Expand all Loading... |
3823 } | 3823 } |
3824 } | 3824 } |
3825 | 3825 |
3826 | 3826 |
3827 var h = { | 3827 var h = { |
3828 "content-type" : "application/json; charset=utf-8", | 3828 "content-type" : "application/json; charset=utf-8", |
3829 }; | 3829 }; |
3830 var resp = convert.JSON.encode(buildTesters()); | 3830 var resp = convert.JSON.encode(buildTesters()); |
3831 return new async.Future.value(stringResponse(200, h, resp)); | 3831 return new async.Future.value(stringResponse(200, h, resp)); |
3832 }), true); | 3832 }), true); |
3833 res.patch(arg_request, arg_packageName, arg_editId, arg_track).then(unitte
st.expectAsync(((api.Testers response) { | 3833 res.patch(arg_request, arg_packageName, arg_editId, arg_track).then(unitte
st.expectAsync1(((api.Testers response) { |
3834 checkTesters(response); | 3834 checkTesters(response); |
3835 }))); | 3835 }))); |
3836 }); | 3836 }); |
3837 | 3837 |
3838 unittest.test("method--update", () { | 3838 unittest.test("method--update", () { |
3839 | 3839 |
3840 var mock = new HttpServerMock(); | 3840 var mock = new HttpServerMock(); |
3841 api.EditsTestersResourceApi res = new api.AndroidpublisherApi(mock).edits.
testers; | 3841 api.EditsTestersResourceApi res = new api.AndroidpublisherApi(mock).edits.
testers; |
3842 var arg_request = buildTesters(); | 3842 var arg_request = buildTesters(); |
3843 var arg_packageName = "foo"; | 3843 var arg_packageName = "foo"; |
3844 var arg_editId = "foo"; | 3844 var arg_editId = "foo"; |
3845 var arg_track = "foo"; | 3845 var arg_track = "foo"; |
3846 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3846 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3847 var obj = new api.Testers.fromJson(json); | 3847 var obj = new api.Testers.fromJson(json); |
3848 checkTesters(obj); | 3848 checkTesters(obj); |
3849 | 3849 |
3850 var path = (req.url).path; | 3850 var path = (req.url).path; |
3851 var pathOffset = 0; | 3851 var pathOffset = 0; |
3852 var index; | 3852 var index; |
3853 var subPart; | 3853 var subPart; |
3854 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3854 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3855 pathOffset += 1; | 3855 pathOffset += 1; |
3856 | 3856 |
(...skipping 14 matching lines...) Expand all Loading... |
3871 } | 3871 } |
3872 } | 3872 } |
3873 | 3873 |
3874 | 3874 |
3875 var h = { | 3875 var h = { |
3876 "content-type" : "application/json; charset=utf-8", | 3876 "content-type" : "application/json; charset=utf-8", |
3877 }; | 3877 }; |
3878 var resp = convert.JSON.encode(buildTesters()); | 3878 var resp = convert.JSON.encode(buildTesters()); |
3879 return new async.Future.value(stringResponse(200, h, resp)); | 3879 return new async.Future.value(stringResponse(200, h, resp)); |
3880 }), true); | 3880 }), true); |
3881 res.update(arg_request, arg_packageName, arg_editId, arg_track).then(unitt
est.expectAsync(((api.Testers response) { | 3881 res.update(arg_request, arg_packageName, arg_editId, arg_track).then(unitt
est.expectAsync1(((api.Testers response) { |
3882 checkTesters(response); | 3882 checkTesters(response); |
3883 }))); | 3883 }))); |
3884 }); | 3884 }); |
3885 | 3885 |
3886 }); | 3886 }); |
3887 | 3887 |
3888 | 3888 |
3889 unittest.group("resource-EditsTracksResourceApi", () { | 3889 unittest.group("resource-EditsTracksResourceApi", () { |
3890 unittest.test("method--get", () { | 3890 unittest.test("method--get", () { |
3891 | 3891 |
3892 var mock = new HttpServerMock(); | 3892 var mock = new HttpServerMock(); |
3893 api.EditsTracksResourceApi res = new api.AndroidpublisherApi(mock).edits.t
racks; | 3893 api.EditsTracksResourceApi res = new api.AndroidpublisherApi(mock).edits.t
racks; |
3894 var arg_packageName = "foo"; | 3894 var arg_packageName = "foo"; |
3895 var arg_editId = "foo"; | 3895 var arg_editId = "foo"; |
3896 var arg_track = "foo"; | 3896 var arg_track = "foo"; |
3897 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3897 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3898 var path = (req.url).path; | 3898 var path = (req.url).path; |
3899 var pathOffset = 0; | 3899 var pathOffset = 0; |
3900 var index; | 3900 var index; |
3901 var subPart; | 3901 var subPart; |
3902 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3902 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3903 pathOffset += 1; | 3903 pathOffset += 1; |
3904 | 3904 |
3905 var query = (req.url).query; | 3905 var query = (req.url).query; |
3906 var queryOffset = 0; | 3906 var queryOffset = 0; |
3907 var queryMap = {}; | 3907 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
3919 } | 3919 } |
3920 } | 3920 } |
3921 | 3921 |
3922 | 3922 |
3923 var h = { | 3923 var h = { |
3924 "content-type" : "application/json; charset=utf-8", | 3924 "content-type" : "application/json; charset=utf-8", |
3925 }; | 3925 }; |
3926 var resp = convert.JSON.encode(buildTrack()); | 3926 var resp = convert.JSON.encode(buildTrack()); |
3927 return new async.Future.value(stringResponse(200, h, resp)); | 3927 return new async.Future.value(stringResponse(200, h, resp)); |
3928 }), true); | 3928 }), true); |
3929 res.get(arg_packageName, arg_editId, arg_track).then(unittest.expectAsync(
((api.Track response) { | 3929 res.get(arg_packageName, arg_editId, arg_track).then(unittest.expectAsync1
(((api.Track response) { |
3930 checkTrack(response); | 3930 checkTrack(response); |
3931 }))); | 3931 }))); |
3932 }); | 3932 }); |
3933 | 3933 |
3934 unittest.test("method--list", () { | 3934 unittest.test("method--list", () { |
3935 | 3935 |
3936 var mock = new HttpServerMock(); | 3936 var mock = new HttpServerMock(); |
3937 api.EditsTracksResourceApi res = new api.AndroidpublisherApi(mock).edits.t
racks; | 3937 api.EditsTracksResourceApi res = new api.AndroidpublisherApi(mock).edits.t
racks; |
3938 var arg_packageName = "foo"; | 3938 var arg_packageName = "foo"; |
3939 var arg_editId = "foo"; | 3939 var arg_editId = "foo"; |
3940 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3940 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3941 var path = (req.url).path; | 3941 var path = (req.url).path; |
3942 var pathOffset = 0; | 3942 var pathOffset = 0; |
3943 var index; | 3943 var index; |
3944 var subPart; | 3944 var subPart; |
3945 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3945 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3946 pathOffset += 1; | 3946 pathOffset += 1; |
3947 | 3947 |
3948 var query = (req.url).query; | 3948 var query = (req.url).query; |
3949 var queryOffset = 0; | 3949 var queryOffset = 0; |
3950 var queryMap = {}; | 3950 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
3962 } | 3962 } |
3963 } | 3963 } |
3964 | 3964 |
3965 | 3965 |
3966 var h = { | 3966 var h = { |
3967 "content-type" : "application/json; charset=utf-8", | 3967 "content-type" : "application/json; charset=utf-8", |
3968 }; | 3968 }; |
3969 var resp = convert.JSON.encode(buildTracksListResponse()); | 3969 var resp = convert.JSON.encode(buildTracksListResponse()); |
3970 return new async.Future.value(stringResponse(200, h, resp)); | 3970 return new async.Future.value(stringResponse(200, h, resp)); |
3971 }), true); | 3971 }), true); |
3972 res.list(arg_packageName, arg_editId).then(unittest.expectAsync(((api.Trac
ksListResponse response) { | 3972 res.list(arg_packageName, arg_editId).then(unittest.expectAsync1(((api.Tra
cksListResponse response) { |
3973 checkTracksListResponse(response); | 3973 checkTracksListResponse(response); |
3974 }))); | 3974 }))); |
3975 }); | 3975 }); |
3976 | 3976 |
3977 unittest.test("method--patch", () { | 3977 unittest.test("method--patch", () { |
3978 | 3978 |
3979 var mock = new HttpServerMock(); | 3979 var mock = new HttpServerMock(); |
3980 api.EditsTracksResourceApi res = new api.AndroidpublisherApi(mock).edits.t
racks; | 3980 api.EditsTracksResourceApi res = new api.AndroidpublisherApi(mock).edits.t
racks; |
3981 var arg_request = buildTrack(); | 3981 var arg_request = buildTrack(); |
3982 var arg_packageName = "foo"; | 3982 var arg_packageName = "foo"; |
3983 var arg_editId = "foo"; | 3983 var arg_editId = "foo"; |
3984 var arg_track = "foo"; | 3984 var arg_track = "foo"; |
3985 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3985 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3986 var obj = new api.Track.fromJson(json); | 3986 var obj = new api.Track.fromJson(json); |
3987 checkTrack(obj); | 3987 checkTrack(obj); |
3988 | 3988 |
3989 var path = (req.url).path; | 3989 var path = (req.url).path; |
3990 var pathOffset = 0; | 3990 var pathOffset = 0; |
3991 var index; | 3991 var index; |
3992 var subPart; | 3992 var subPart; |
3993 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3993 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3994 pathOffset += 1; | 3994 pathOffset += 1; |
3995 | 3995 |
(...skipping 14 matching lines...) Expand all Loading... |
4010 } | 4010 } |
4011 } | 4011 } |
4012 | 4012 |
4013 | 4013 |
4014 var h = { | 4014 var h = { |
4015 "content-type" : "application/json; charset=utf-8", | 4015 "content-type" : "application/json; charset=utf-8", |
4016 }; | 4016 }; |
4017 var resp = convert.JSON.encode(buildTrack()); | 4017 var resp = convert.JSON.encode(buildTrack()); |
4018 return new async.Future.value(stringResponse(200, h, resp)); | 4018 return new async.Future.value(stringResponse(200, h, resp)); |
4019 }), true); | 4019 }), true); |
4020 res.patch(arg_request, arg_packageName, arg_editId, arg_track).then(unitte
st.expectAsync(((api.Track response) { | 4020 res.patch(arg_request, arg_packageName, arg_editId, arg_track).then(unitte
st.expectAsync1(((api.Track response) { |
4021 checkTrack(response); | 4021 checkTrack(response); |
4022 }))); | 4022 }))); |
4023 }); | 4023 }); |
4024 | 4024 |
4025 unittest.test("method--update", () { | 4025 unittest.test("method--update", () { |
4026 | 4026 |
4027 var mock = new HttpServerMock(); | 4027 var mock = new HttpServerMock(); |
4028 api.EditsTracksResourceApi res = new api.AndroidpublisherApi(mock).edits.t
racks; | 4028 api.EditsTracksResourceApi res = new api.AndroidpublisherApi(mock).edits.t
racks; |
4029 var arg_request = buildTrack(); | 4029 var arg_request = buildTrack(); |
4030 var arg_packageName = "foo"; | 4030 var arg_packageName = "foo"; |
4031 var arg_editId = "foo"; | 4031 var arg_editId = "foo"; |
4032 var arg_track = "foo"; | 4032 var arg_track = "foo"; |
4033 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 4033 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
4034 var obj = new api.Track.fromJson(json); | 4034 var obj = new api.Track.fromJson(json); |
4035 checkTrack(obj); | 4035 checkTrack(obj); |
4036 | 4036 |
4037 var path = (req.url).path; | 4037 var path = (req.url).path; |
4038 var pathOffset = 0; | 4038 var pathOffset = 0; |
4039 var index; | 4039 var index; |
4040 var subPart; | 4040 var subPart; |
4041 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 4041 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
4042 pathOffset += 1; | 4042 pathOffset += 1; |
4043 | 4043 |
(...skipping 14 matching lines...) Expand all Loading... |
4058 } | 4058 } |
4059 } | 4059 } |
4060 | 4060 |
4061 | 4061 |
4062 var h = { | 4062 var h = { |
4063 "content-type" : "application/json; charset=utf-8", | 4063 "content-type" : "application/json; charset=utf-8", |
4064 }; | 4064 }; |
4065 var resp = convert.JSON.encode(buildTrack()); | 4065 var resp = convert.JSON.encode(buildTrack()); |
4066 return new async.Future.value(stringResponse(200, h, resp)); | 4066 return new async.Future.value(stringResponse(200, h, resp)); |
4067 }), true); | 4067 }), true); |
4068 res.update(arg_request, arg_packageName, arg_editId, arg_track).then(unitt
est.expectAsync(((api.Track response) { | 4068 res.update(arg_request, arg_packageName, arg_editId, arg_track).then(unitt
est.expectAsync1(((api.Track response) { |
4069 checkTrack(response); | 4069 checkTrack(response); |
4070 }))); | 4070 }))); |
4071 }); | 4071 }); |
4072 | 4072 |
4073 }); | 4073 }); |
4074 | 4074 |
4075 | 4075 |
4076 unittest.group("resource-EntitlementsResourceApi", () { | 4076 unittest.group("resource-EntitlementsResourceApi", () { |
4077 unittest.test("method--list", () { | 4077 unittest.test("method--list", () { |
4078 | 4078 |
4079 var mock = new HttpServerMock(); | 4079 var mock = new HttpServerMock(); |
4080 api.EntitlementsResourceApi res = new api.AndroidpublisherApi(mock).entitl
ements; | 4080 api.EntitlementsResourceApi res = new api.AndroidpublisherApi(mock).entitl
ements; |
4081 var arg_packageName = "foo"; | 4081 var arg_packageName = "foo"; |
4082 var arg_maxResults = 42; | 4082 var arg_maxResults = 42; |
4083 var arg_productId = "foo"; | 4083 var arg_productId = "foo"; |
4084 var arg_startIndex = 42; | 4084 var arg_startIndex = 42; |
4085 var arg_token = "foo"; | 4085 var arg_token = "foo"; |
4086 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 4086 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
4087 var path = (req.url).path; | 4087 var path = (req.url).path; |
4088 var pathOffset = 0; | 4088 var pathOffset = 0; |
4089 var index; | 4089 var index; |
4090 var subPart; | 4090 var subPart; |
4091 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 4091 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
4092 pathOffset += 1; | 4092 pathOffset += 1; |
4093 | 4093 |
4094 var query = (req.url).query; | 4094 var query = (req.url).query; |
4095 var queryOffset = 0; | 4095 var queryOffset = 0; |
4096 var queryMap = {}; | 4096 var queryMap = {}; |
(...skipping 15 matching lines...) Expand all Loading... |
4112 unittest.expect(core.int.parse(queryMap["startIndex"].first), unittest.e
quals(arg_startIndex)); | 4112 unittest.expect(core.int.parse(queryMap["startIndex"].first), unittest.e
quals(arg_startIndex)); |
4113 unittest.expect(queryMap["token"].first, unittest.equals(arg_token)); | 4113 unittest.expect(queryMap["token"].first, unittest.equals(arg_token)); |
4114 | 4114 |
4115 | 4115 |
4116 var h = { | 4116 var h = { |
4117 "content-type" : "application/json; charset=utf-8", | 4117 "content-type" : "application/json; charset=utf-8", |
4118 }; | 4118 }; |
4119 var resp = convert.JSON.encode(buildEntitlementsListResponse()); | 4119 var resp = convert.JSON.encode(buildEntitlementsListResponse()); |
4120 return new async.Future.value(stringResponse(200, h, resp)); | 4120 return new async.Future.value(stringResponse(200, h, resp)); |
4121 }), true); | 4121 }), true); |
4122 res.list(arg_packageName, maxResults: arg_maxResults, productId: arg_produ
ctId, startIndex: arg_startIndex, token: arg_token).then(unittest.expectAsync(((
api.EntitlementsListResponse response) { | 4122 res.list(arg_packageName, maxResults: arg_maxResults, productId: arg_produ
ctId, startIndex: arg_startIndex, token: arg_token).then(unittest.expectAsync1((
(api.EntitlementsListResponse response) { |
4123 checkEntitlementsListResponse(response); | 4123 checkEntitlementsListResponse(response); |
4124 }))); | 4124 }))); |
4125 }); | 4125 }); |
4126 | 4126 |
4127 }); | 4127 }); |
4128 | 4128 |
4129 | 4129 |
4130 unittest.group("resource-InappproductsResourceApi", () { | 4130 unittest.group("resource-InappproductsResourceApi", () { |
4131 unittest.test("method--batch", () { | 4131 unittest.test("method--batch", () { |
4132 | 4132 |
4133 var mock = new HttpServerMock(); | 4133 var mock = new HttpServerMock(); |
4134 api.InappproductsResourceApi res = new api.AndroidpublisherApi(mock).inapp
products; | 4134 api.InappproductsResourceApi res = new api.AndroidpublisherApi(mock).inapp
products; |
4135 var arg_request = buildInappproductsBatchRequest(); | 4135 var arg_request = buildInappproductsBatchRequest(); |
4136 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 4136 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
4137 var obj = new api.InappproductsBatchRequest.fromJson(json); | 4137 var obj = new api.InappproductsBatchRequest.fromJson(json); |
4138 checkInappproductsBatchRequest(obj); | 4138 checkInappproductsBatchRequest(obj); |
4139 | 4139 |
4140 var path = (req.url).path; | 4140 var path = (req.url).path; |
4141 var pathOffset = 0; | 4141 var pathOffset = 0; |
4142 var index; | 4142 var index; |
4143 var subPart; | 4143 var subPart; |
4144 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 4144 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
4145 pathOffset += 1; | 4145 pathOffset += 1; |
4146 unittest.expect(path.substring(pathOffset, pathOffset + 33), unittest.eq
uals("androidpublisher/v2/applications/")); | 4146 unittest.expect(path.substring(pathOffset, pathOffset + 33), unittest.eq
uals("androidpublisher/v2/applications/")); |
(...skipping 18 matching lines...) Expand all Loading... |
4165 } | 4165 } |
4166 } | 4166 } |
4167 | 4167 |
4168 | 4168 |
4169 var h = { | 4169 var h = { |
4170 "content-type" : "application/json; charset=utf-8", | 4170 "content-type" : "application/json; charset=utf-8", |
4171 }; | 4171 }; |
4172 var resp = convert.JSON.encode(buildInappproductsBatchResponse()); | 4172 var resp = convert.JSON.encode(buildInappproductsBatchResponse()); |
4173 return new async.Future.value(stringResponse(200, h, resp)); | 4173 return new async.Future.value(stringResponse(200, h, resp)); |
4174 }), true); | 4174 }), true); |
4175 res.batch(arg_request).then(unittest.expectAsync(((api.InappproductsBatchR
esponse response) { | 4175 res.batch(arg_request).then(unittest.expectAsync1(((api.InappproductsBatch
Response response) { |
4176 checkInappproductsBatchResponse(response); | 4176 checkInappproductsBatchResponse(response); |
4177 }))); | 4177 }))); |
4178 }); | 4178 }); |
4179 | 4179 |
4180 unittest.test("method--delete", () { | 4180 unittest.test("method--delete", () { |
4181 | 4181 |
4182 var mock = new HttpServerMock(); | 4182 var mock = new HttpServerMock(); |
4183 api.InappproductsResourceApi res = new api.AndroidpublisherApi(mock).inapp
products; | 4183 api.InappproductsResourceApi res = new api.AndroidpublisherApi(mock).inapp
products; |
4184 var arg_packageName = "foo"; | 4184 var arg_packageName = "foo"; |
4185 var arg_sku = "foo"; | 4185 var arg_sku = "foo"; |
4186 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 4186 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
4187 var path = (req.url).path; | 4187 var path = (req.url).path; |
4188 var pathOffset = 0; | 4188 var pathOffset = 0; |
4189 var index; | 4189 var index; |
4190 var subPart; | 4190 var subPart; |
4191 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 4191 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
4192 pathOffset += 1; | 4192 pathOffset += 1; |
4193 | 4193 |
4194 var query = (req.url).query; | 4194 var query = (req.url).query; |
4195 var queryOffset = 0; | 4195 var queryOffset = 0; |
4196 var queryMap = {}; | 4196 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
4208 } | 4208 } |
4209 } | 4209 } |
4210 | 4210 |
4211 | 4211 |
4212 var h = { | 4212 var h = { |
4213 "content-type" : "application/json; charset=utf-8", | 4213 "content-type" : "application/json; charset=utf-8", |
4214 }; | 4214 }; |
4215 var resp = ""; | 4215 var resp = ""; |
4216 return new async.Future.value(stringResponse(200, h, resp)); | 4216 return new async.Future.value(stringResponse(200, h, resp)); |
4217 }), true); | 4217 }), true); |
4218 res.delete(arg_packageName, arg_sku).then(unittest.expectAsync((_) {})); | 4218 res.delete(arg_packageName, arg_sku).then(unittest.expectAsync1((_) {})); |
4219 }); | 4219 }); |
4220 | 4220 |
4221 unittest.test("method--get", () { | 4221 unittest.test("method--get", () { |
4222 | 4222 |
4223 var mock = new HttpServerMock(); | 4223 var mock = new HttpServerMock(); |
4224 api.InappproductsResourceApi res = new api.AndroidpublisherApi(mock).inapp
products; | 4224 api.InappproductsResourceApi res = new api.AndroidpublisherApi(mock).inapp
products; |
4225 var arg_packageName = "foo"; | 4225 var arg_packageName = "foo"; |
4226 var arg_sku = "foo"; | 4226 var arg_sku = "foo"; |
4227 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 4227 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
4228 var path = (req.url).path; | 4228 var path = (req.url).path; |
4229 var pathOffset = 0; | 4229 var pathOffset = 0; |
4230 var index; | 4230 var index; |
4231 var subPart; | 4231 var subPart; |
4232 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 4232 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
4233 pathOffset += 1; | 4233 pathOffset += 1; |
4234 | 4234 |
4235 var query = (req.url).query; | 4235 var query = (req.url).query; |
4236 var queryOffset = 0; | 4236 var queryOffset = 0; |
4237 var queryMap = {}; | 4237 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
4249 } | 4249 } |
4250 } | 4250 } |
4251 | 4251 |
4252 | 4252 |
4253 var h = { | 4253 var h = { |
4254 "content-type" : "application/json; charset=utf-8", | 4254 "content-type" : "application/json; charset=utf-8", |
4255 }; | 4255 }; |
4256 var resp = convert.JSON.encode(buildInAppProduct()); | 4256 var resp = convert.JSON.encode(buildInAppProduct()); |
4257 return new async.Future.value(stringResponse(200, h, resp)); | 4257 return new async.Future.value(stringResponse(200, h, resp)); |
4258 }), true); | 4258 }), true); |
4259 res.get(arg_packageName, arg_sku).then(unittest.expectAsync(((api.InAppPro
duct response) { | 4259 res.get(arg_packageName, arg_sku).then(unittest.expectAsync1(((api.InAppPr
oduct response) { |
4260 checkInAppProduct(response); | 4260 checkInAppProduct(response); |
4261 }))); | 4261 }))); |
4262 }); | 4262 }); |
4263 | 4263 |
4264 unittest.test("method--insert", () { | 4264 unittest.test("method--insert", () { |
4265 | 4265 |
4266 var mock = new HttpServerMock(); | 4266 var mock = new HttpServerMock(); |
4267 api.InappproductsResourceApi res = new api.AndroidpublisherApi(mock).inapp
products; | 4267 api.InappproductsResourceApi res = new api.AndroidpublisherApi(mock).inapp
products; |
4268 var arg_request = buildInAppProduct(); | 4268 var arg_request = buildInAppProduct(); |
4269 var arg_packageName = "foo"; | 4269 var arg_packageName = "foo"; |
4270 var arg_autoConvertMissingPrices = true; | 4270 var arg_autoConvertMissingPrices = true; |
4271 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 4271 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
4272 var obj = new api.InAppProduct.fromJson(json); | 4272 var obj = new api.InAppProduct.fromJson(json); |
4273 checkInAppProduct(obj); | 4273 checkInAppProduct(obj); |
4274 | 4274 |
4275 var path = (req.url).path; | 4275 var path = (req.url).path; |
4276 var pathOffset = 0; | 4276 var pathOffset = 0; |
4277 var index; | 4277 var index; |
4278 var subPart; | 4278 var subPart; |
4279 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 4279 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
4280 pathOffset += 1; | 4280 pathOffset += 1; |
4281 | 4281 |
(...skipping 15 matching lines...) Expand all Loading... |
4297 } | 4297 } |
4298 unittest.expect(queryMap["autoConvertMissingPrices"].first, unittest.equ
als("$arg_autoConvertMissingPrices")); | 4298 unittest.expect(queryMap["autoConvertMissingPrices"].first, unittest.equ
als("$arg_autoConvertMissingPrices")); |
4299 | 4299 |
4300 | 4300 |
4301 var h = { | 4301 var h = { |
4302 "content-type" : "application/json; charset=utf-8", | 4302 "content-type" : "application/json; charset=utf-8", |
4303 }; | 4303 }; |
4304 var resp = convert.JSON.encode(buildInAppProduct()); | 4304 var resp = convert.JSON.encode(buildInAppProduct()); |
4305 return new async.Future.value(stringResponse(200, h, resp)); | 4305 return new async.Future.value(stringResponse(200, h, resp)); |
4306 }), true); | 4306 }), true); |
4307 res.insert(arg_request, arg_packageName, autoConvertMissingPrices: arg_aut
oConvertMissingPrices).then(unittest.expectAsync(((api.InAppProduct response) { | 4307 res.insert(arg_request, arg_packageName, autoConvertMissingPrices: arg_aut
oConvertMissingPrices).then(unittest.expectAsync1(((api.InAppProduct response) { |
4308 checkInAppProduct(response); | 4308 checkInAppProduct(response); |
4309 }))); | 4309 }))); |
4310 }); | 4310 }); |
4311 | 4311 |
4312 unittest.test("method--list", () { | 4312 unittest.test("method--list", () { |
4313 | 4313 |
4314 var mock = new HttpServerMock(); | 4314 var mock = new HttpServerMock(); |
4315 api.InappproductsResourceApi res = new api.AndroidpublisherApi(mock).inapp
products; | 4315 api.InappproductsResourceApi res = new api.AndroidpublisherApi(mock).inapp
products; |
4316 var arg_packageName = "foo"; | 4316 var arg_packageName = "foo"; |
4317 var arg_maxResults = 42; | 4317 var arg_maxResults = 42; |
4318 var arg_startIndex = 42; | 4318 var arg_startIndex = 42; |
4319 var arg_token = "foo"; | 4319 var arg_token = "foo"; |
4320 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 4320 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
4321 var path = (req.url).path; | 4321 var path = (req.url).path; |
4322 var pathOffset = 0; | 4322 var pathOffset = 0; |
4323 var index; | 4323 var index; |
4324 var subPart; | 4324 var subPart; |
4325 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 4325 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
4326 pathOffset += 1; | 4326 pathOffset += 1; |
4327 | 4327 |
4328 var query = (req.url).query; | 4328 var query = (req.url).query; |
4329 var queryOffset = 0; | 4329 var queryOffset = 0; |
4330 var queryMap = {}; | 4330 var queryMap = {}; |
(...skipping 14 matching lines...) Expand all Loading... |
4345 unittest.expect(core.int.parse(queryMap["startIndex"].first), unittest.e
quals(arg_startIndex)); | 4345 unittest.expect(core.int.parse(queryMap["startIndex"].first), unittest.e
quals(arg_startIndex)); |
4346 unittest.expect(queryMap["token"].first, unittest.equals(arg_token)); | 4346 unittest.expect(queryMap["token"].first, unittest.equals(arg_token)); |
4347 | 4347 |
4348 | 4348 |
4349 var h = { | 4349 var h = { |
4350 "content-type" : "application/json; charset=utf-8", | 4350 "content-type" : "application/json; charset=utf-8", |
4351 }; | 4351 }; |
4352 var resp = convert.JSON.encode(buildInappproductsListResponse()); | 4352 var resp = convert.JSON.encode(buildInappproductsListResponse()); |
4353 return new async.Future.value(stringResponse(200, h, resp)); | 4353 return new async.Future.value(stringResponse(200, h, resp)); |
4354 }), true); | 4354 }), true); |
4355 res.list(arg_packageName, maxResults: arg_maxResults, startIndex: arg_star
tIndex, token: arg_token).then(unittest.expectAsync(((api.InappproductsListRespo
nse response) { | 4355 res.list(arg_packageName, maxResults: arg_maxResults, startIndex: arg_star
tIndex, token: arg_token).then(unittest.expectAsync1(((api.InappproductsListResp
onse response) { |
4356 checkInappproductsListResponse(response); | 4356 checkInappproductsListResponse(response); |
4357 }))); | 4357 }))); |
4358 }); | 4358 }); |
4359 | 4359 |
4360 unittest.test("method--patch", () { | 4360 unittest.test("method--patch", () { |
4361 | 4361 |
4362 var mock = new HttpServerMock(); | 4362 var mock = new HttpServerMock(); |
4363 api.InappproductsResourceApi res = new api.AndroidpublisherApi(mock).inapp
products; | 4363 api.InappproductsResourceApi res = new api.AndroidpublisherApi(mock).inapp
products; |
4364 var arg_request = buildInAppProduct(); | 4364 var arg_request = buildInAppProduct(); |
4365 var arg_packageName = "foo"; | 4365 var arg_packageName = "foo"; |
4366 var arg_sku = "foo"; | 4366 var arg_sku = "foo"; |
4367 var arg_autoConvertMissingPrices = true; | 4367 var arg_autoConvertMissingPrices = true; |
4368 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 4368 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
4369 var obj = new api.InAppProduct.fromJson(json); | 4369 var obj = new api.InAppProduct.fromJson(json); |
4370 checkInAppProduct(obj); | 4370 checkInAppProduct(obj); |
4371 | 4371 |
4372 var path = (req.url).path; | 4372 var path = (req.url).path; |
4373 var pathOffset = 0; | 4373 var pathOffset = 0; |
4374 var index; | 4374 var index; |
4375 var subPart; | 4375 var subPart; |
4376 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 4376 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
4377 pathOffset += 1; | 4377 pathOffset += 1; |
4378 | 4378 |
(...skipping 15 matching lines...) Expand all Loading... |
4394 } | 4394 } |
4395 unittest.expect(queryMap["autoConvertMissingPrices"].first, unittest.equ
als("$arg_autoConvertMissingPrices")); | 4395 unittest.expect(queryMap["autoConvertMissingPrices"].first, unittest.equ
als("$arg_autoConvertMissingPrices")); |
4396 | 4396 |
4397 | 4397 |
4398 var h = { | 4398 var h = { |
4399 "content-type" : "application/json; charset=utf-8", | 4399 "content-type" : "application/json; charset=utf-8", |
4400 }; | 4400 }; |
4401 var resp = convert.JSON.encode(buildInAppProduct()); | 4401 var resp = convert.JSON.encode(buildInAppProduct()); |
4402 return new async.Future.value(stringResponse(200, h, resp)); | 4402 return new async.Future.value(stringResponse(200, h, resp)); |
4403 }), true); | 4403 }), true); |
4404 res.patch(arg_request, arg_packageName, arg_sku, autoConvertMissingPrices:
arg_autoConvertMissingPrices).then(unittest.expectAsync(((api.InAppProduct resp
onse) { | 4404 res.patch(arg_request, arg_packageName, arg_sku, autoConvertMissingPrices:
arg_autoConvertMissingPrices).then(unittest.expectAsync1(((api.InAppProduct res
ponse) { |
4405 checkInAppProduct(response); | 4405 checkInAppProduct(response); |
4406 }))); | 4406 }))); |
4407 }); | 4407 }); |
4408 | 4408 |
4409 unittest.test("method--update", () { | 4409 unittest.test("method--update", () { |
4410 | 4410 |
4411 var mock = new HttpServerMock(); | 4411 var mock = new HttpServerMock(); |
4412 api.InappproductsResourceApi res = new api.AndroidpublisherApi(mock).inapp
products; | 4412 api.InappproductsResourceApi res = new api.AndroidpublisherApi(mock).inapp
products; |
4413 var arg_request = buildInAppProduct(); | 4413 var arg_request = buildInAppProduct(); |
4414 var arg_packageName = "foo"; | 4414 var arg_packageName = "foo"; |
4415 var arg_sku = "foo"; | 4415 var arg_sku = "foo"; |
4416 var arg_autoConvertMissingPrices = true; | 4416 var arg_autoConvertMissingPrices = true; |
4417 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 4417 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
4418 var obj = new api.InAppProduct.fromJson(json); | 4418 var obj = new api.InAppProduct.fromJson(json); |
4419 checkInAppProduct(obj); | 4419 checkInAppProduct(obj); |
4420 | 4420 |
4421 var path = (req.url).path; | 4421 var path = (req.url).path; |
4422 var pathOffset = 0; | 4422 var pathOffset = 0; |
4423 var index; | 4423 var index; |
4424 var subPart; | 4424 var subPart; |
4425 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 4425 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
4426 pathOffset += 1; | 4426 pathOffset += 1; |
4427 | 4427 |
(...skipping 15 matching lines...) Expand all Loading... |
4443 } | 4443 } |
4444 unittest.expect(queryMap["autoConvertMissingPrices"].first, unittest.equ
als("$arg_autoConvertMissingPrices")); | 4444 unittest.expect(queryMap["autoConvertMissingPrices"].first, unittest.equ
als("$arg_autoConvertMissingPrices")); |
4445 | 4445 |
4446 | 4446 |
4447 var h = { | 4447 var h = { |
4448 "content-type" : "application/json; charset=utf-8", | 4448 "content-type" : "application/json; charset=utf-8", |
4449 }; | 4449 }; |
4450 var resp = convert.JSON.encode(buildInAppProduct()); | 4450 var resp = convert.JSON.encode(buildInAppProduct()); |
4451 return new async.Future.value(stringResponse(200, h, resp)); | 4451 return new async.Future.value(stringResponse(200, h, resp)); |
4452 }), true); | 4452 }), true); |
4453 res.update(arg_request, arg_packageName, arg_sku, autoConvertMissingPrices
: arg_autoConvertMissingPrices).then(unittest.expectAsync(((api.InAppProduct res
ponse) { | 4453 res.update(arg_request, arg_packageName, arg_sku, autoConvertMissingPrices
: arg_autoConvertMissingPrices).then(unittest.expectAsync1(((api.InAppProduct re
sponse) { |
4454 checkInAppProduct(response); | 4454 checkInAppProduct(response); |
4455 }))); | 4455 }))); |
4456 }); | 4456 }); |
4457 | 4457 |
4458 }); | 4458 }); |
4459 | 4459 |
4460 | 4460 |
4461 unittest.group("resource-PurchasesProductsResourceApi", () { | 4461 unittest.group("resource-PurchasesProductsResourceApi", () { |
4462 unittest.test("method--get", () { | 4462 unittest.test("method--get", () { |
4463 | 4463 |
4464 var mock = new HttpServerMock(); | 4464 var mock = new HttpServerMock(); |
4465 api.PurchasesProductsResourceApi res = new api.AndroidpublisherApi(mock).p
urchases.products; | 4465 api.PurchasesProductsResourceApi res = new api.AndroidpublisherApi(mock).p
urchases.products; |
4466 var arg_packageName = "foo"; | 4466 var arg_packageName = "foo"; |
4467 var arg_productId = "foo"; | 4467 var arg_productId = "foo"; |
4468 var arg_token = "foo"; | 4468 var arg_token = "foo"; |
4469 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 4469 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
4470 var path = (req.url).path; | 4470 var path = (req.url).path; |
4471 var pathOffset = 0; | 4471 var pathOffset = 0; |
4472 var index; | 4472 var index; |
4473 var subPart; | 4473 var subPart; |
4474 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 4474 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
4475 pathOffset += 1; | 4475 pathOffset += 1; |
4476 | 4476 |
4477 var query = (req.url).query; | 4477 var query = (req.url).query; |
4478 var queryOffset = 0; | 4478 var queryOffset = 0; |
4479 var queryMap = {}; | 4479 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
4491 } | 4491 } |
4492 } | 4492 } |
4493 | 4493 |
4494 | 4494 |
4495 var h = { | 4495 var h = { |
4496 "content-type" : "application/json; charset=utf-8", | 4496 "content-type" : "application/json; charset=utf-8", |
4497 }; | 4497 }; |
4498 var resp = convert.JSON.encode(buildProductPurchase()); | 4498 var resp = convert.JSON.encode(buildProductPurchase()); |
4499 return new async.Future.value(stringResponse(200, h, resp)); | 4499 return new async.Future.value(stringResponse(200, h, resp)); |
4500 }), true); | 4500 }), true); |
4501 res.get(arg_packageName, arg_productId, arg_token).then(unittest.expectAsy
nc(((api.ProductPurchase response) { | 4501 res.get(arg_packageName, arg_productId, arg_token).then(unittest.expectAsy
nc1(((api.ProductPurchase response) { |
4502 checkProductPurchase(response); | 4502 checkProductPurchase(response); |
4503 }))); | 4503 }))); |
4504 }); | 4504 }); |
4505 | 4505 |
4506 }); | 4506 }); |
4507 | 4507 |
4508 | 4508 |
4509 unittest.group("resource-PurchasesSubscriptionsResourceApi", () { | 4509 unittest.group("resource-PurchasesSubscriptionsResourceApi", () { |
4510 unittest.test("method--cancel", () { | 4510 unittest.test("method--cancel", () { |
4511 | 4511 |
4512 var mock = new HttpServerMock(); | 4512 var mock = new HttpServerMock(); |
4513 api.PurchasesSubscriptionsResourceApi res = new api.AndroidpublisherApi(mo
ck).purchases.subscriptions; | 4513 api.PurchasesSubscriptionsResourceApi res = new api.AndroidpublisherApi(mo
ck).purchases.subscriptions; |
4514 var arg_packageName = "foo"; | 4514 var arg_packageName = "foo"; |
4515 var arg_subscriptionId = "foo"; | 4515 var arg_subscriptionId = "foo"; |
4516 var arg_token = "foo"; | 4516 var arg_token = "foo"; |
4517 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 4517 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
4518 var path = (req.url).path; | 4518 var path = (req.url).path; |
4519 var pathOffset = 0; | 4519 var pathOffset = 0; |
4520 var index; | 4520 var index; |
4521 var subPart; | 4521 var subPart; |
4522 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 4522 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
4523 pathOffset += 1; | 4523 pathOffset += 1; |
4524 | 4524 |
4525 var query = (req.url).query; | 4525 var query = (req.url).query; |
4526 var queryOffset = 0; | 4526 var queryOffset = 0; |
4527 var queryMap = {}; | 4527 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
4539 } | 4539 } |
4540 } | 4540 } |
4541 | 4541 |
4542 | 4542 |
4543 var h = { | 4543 var h = { |
4544 "content-type" : "application/json; charset=utf-8", | 4544 "content-type" : "application/json; charset=utf-8", |
4545 }; | 4545 }; |
4546 var resp = ""; | 4546 var resp = ""; |
4547 return new async.Future.value(stringResponse(200, h, resp)); | 4547 return new async.Future.value(stringResponse(200, h, resp)); |
4548 }), true); | 4548 }), true); |
4549 res.cancel(arg_packageName, arg_subscriptionId, arg_token).then(unittest.e
xpectAsync((_) {})); | 4549 res.cancel(arg_packageName, arg_subscriptionId, arg_token).then(unittest.e
xpectAsync1((_) {})); |
4550 }); | 4550 }); |
4551 | 4551 |
4552 unittest.test("method--defer", () { | 4552 unittest.test("method--defer", () { |
4553 | 4553 |
4554 var mock = new HttpServerMock(); | 4554 var mock = new HttpServerMock(); |
4555 api.PurchasesSubscriptionsResourceApi res = new api.AndroidpublisherApi(mo
ck).purchases.subscriptions; | 4555 api.PurchasesSubscriptionsResourceApi res = new api.AndroidpublisherApi(mo
ck).purchases.subscriptions; |
4556 var arg_request = buildSubscriptionPurchasesDeferRequest(); | 4556 var arg_request = buildSubscriptionPurchasesDeferRequest(); |
4557 var arg_packageName = "foo"; | 4557 var arg_packageName = "foo"; |
4558 var arg_subscriptionId = "foo"; | 4558 var arg_subscriptionId = "foo"; |
4559 var arg_token = "foo"; | 4559 var arg_token = "foo"; |
4560 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 4560 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
4561 var obj = new api.SubscriptionPurchasesDeferRequest.fromJson(json); | 4561 var obj = new api.SubscriptionPurchasesDeferRequest.fromJson(json); |
4562 checkSubscriptionPurchasesDeferRequest(obj); | 4562 checkSubscriptionPurchasesDeferRequest(obj); |
4563 | 4563 |
4564 var path = (req.url).path; | 4564 var path = (req.url).path; |
4565 var pathOffset = 0; | 4565 var pathOffset = 0; |
4566 var index; | 4566 var index; |
4567 var subPart; | 4567 var subPart; |
4568 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 4568 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
4569 pathOffset += 1; | 4569 pathOffset += 1; |
4570 | 4570 |
(...skipping 14 matching lines...) Expand all Loading... |
4585 } | 4585 } |
4586 } | 4586 } |
4587 | 4587 |
4588 | 4588 |
4589 var h = { | 4589 var h = { |
4590 "content-type" : "application/json; charset=utf-8", | 4590 "content-type" : "application/json; charset=utf-8", |
4591 }; | 4591 }; |
4592 var resp = convert.JSON.encode(buildSubscriptionPurchasesDeferResponse()
); | 4592 var resp = convert.JSON.encode(buildSubscriptionPurchasesDeferResponse()
); |
4593 return new async.Future.value(stringResponse(200, h, resp)); | 4593 return new async.Future.value(stringResponse(200, h, resp)); |
4594 }), true); | 4594 }), true); |
4595 res.defer(arg_request, arg_packageName, arg_subscriptionId, arg_token).the
n(unittest.expectAsync(((api.SubscriptionPurchasesDeferResponse response) { | 4595 res.defer(arg_request, arg_packageName, arg_subscriptionId, arg_token).the
n(unittest.expectAsync1(((api.SubscriptionPurchasesDeferResponse response) { |
4596 checkSubscriptionPurchasesDeferResponse(response); | 4596 checkSubscriptionPurchasesDeferResponse(response); |
4597 }))); | 4597 }))); |
4598 }); | 4598 }); |
4599 | 4599 |
4600 unittest.test("method--get", () { | 4600 unittest.test("method--get", () { |
4601 | 4601 |
4602 var mock = new HttpServerMock(); | 4602 var mock = new HttpServerMock(); |
4603 api.PurchasesSubscriptionsResourceApi res = new api.AndroidpublisherApi(mo
ck).purchases.subscriptions; | 4603 api.PurchasesSubscriptionsResourceApi res = new api.AndroidpublisherApi(mo
ck).purchases.subscriptions; |
4604 var arg_packageName = "foo"; | 4604 var arg_packageName = "foo"; |
4605 var arg_subscriptionId = "foo"; | 4605 var arg_subscriptionId = "foo"; |
4606 var arg_token = "foo"; | 4606 var arg_token = "foo"; |
4607 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 4607 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
4608 var path = (req.url).path; | 4608 var path = (req.url).path; |
4609 var pathOffset = 0; | 4609 var pathOffset = 0; |
4610 var index; | 4610 var index; |
4611 var subPart; | 4611 var subPart; |
4612 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 4612 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
4613 pathOffset += 1; | 4613 pathOffset += 1; |
4614 | 4614 |
4615 var query = (req.url).query; | 4615 var query = (req.url).query; |
4616 var queryOffset = 0; | 4616 var queryOffset = 0; |
4617 var queryMap = {}; | 4617 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
4629 } | 4629 } |
4630 } | 4630 } |
4631 | 4631 |
4632 | 4632 |
4633 var h = { | 4633 var h = { |
4634 "content-type" : "application/json; charset=utf-8", | 4634 "content-type" : "application/json; charset=utf-8", |
4635 }; | 4635 }; |
4636 var resp = convert.JSON.encode(buildSubscriptionPurchase()); | 4636 var resp = convert.JSON.encode(buildSubscriptionPurchase()); |
4637 return new async.Future.value(stringResponse(200, h, resp)); | 4637 return new async.Future.value(stringResponse(200, h, resp)); |
4638 }), true); | 4638 }), true); |
4639 res.get(arg_packageName, arg_subscriptionId, arg_token).then(unittest.expe
ctAsync(((api.SubscriptionPurchase response) { | 4639 res.get(arg_packageName, arg_subscriptionId, arg_token).then(unittest.expe
ctAsync1(((api.SubscriptionPurchase response) { |
4640 checkSubscriptionPurchase(response); | 4640 checkSubscriptionPurchase(response); |
4641 }))); | 4641 }))); |
4642 }); | 4642 }); |
4643 | 4643 |
4644 unittest.test("method--refund", () { | 4644 unittest.test("method--refund", () { |
4645 | 4645 |
4646 var mock = new HttpServerMock(); | 4646 var mock = new HttpServerMock(); |
4647 api.PurchasesSubscriptionsResourceApi res = new api.AndroidpublisherApi(mo
ck).purchases.subscriptions; | 4647 api.PurchasesSubscriptionsResourceApi res = new api.AndroidpublisherApi(mo
ck).purchases.subscriptions; |
4648 var arg_packageName = "foo"; | 4648 var arg_packageName = "foo"; |
4649 var arg_subscriptionId = "foo"; | 4649 var arg_subscriptionId = "foo"; |
4650 var arg_token = "foo"; | 4650 var arg_token = "foo"; |
4651 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 4651 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
4652 var path = (req.url).path; | 4652 var path = (req.url).path; |
4653 var pathOffset = 0; | 4653 var pathOffset = 0; |
4654 var index; | 4654 var index; |
4655 var subPart; | 4655 var subPart; |
4656 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 4656 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
4657 pathOffset += 1; | 4657 pathOffset += 1; |
4658 | 4658 |
4659 var query = (req.url).query; | 4659 var query = (req.url).query; |
4660 var queryOffset = 0; | 4660 var queryOffset = 0; |
4661 var queryMap = {}; | 4661 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
4673 } | 4673 } |
4674 } | 4674 } |
4675 | 4675 |
4676 | 4676 |
4677 var h = { | 4677 var h = { |
4678 "content-type" : "application/json; charset=utf-8", | 4678 "content-type" : "application/json; charset=utf-8", |
4679 }; | 4679 }; |
4680 var resp = ""; | 4680 var resp = ""; |
4681 return new async.Future.value(stringResponse(200, h, resp)); | 4681 return new async.Future.value(stringResponse(200, h, resp)); |
4682 }), true); | 4682 }), true); |
4683 res.refund(arg_packageName, arg_subscriptionId, arg_token).then(unittest.e
xpectAsync((_) {})); | 4683 res.refund(arg_packageName, arg_subscriptionId, arg_token).then(unittest.e
xpectAsync1((_) {})); |
4684 }); | 4684 }); |
4685 | 4685 |
4686 unittest.test("method--revoke", () { | 4686 unittest.test("method--revoke", () { |
4687 | 4687 |
4688 var mock = new HttpServerMock(); | 4688 var mock = new HttpServerMock(); |
4689 api.PurchasesSubscriptionsResourceApi res = new api.AndroidpublisherApi(mo
ck).purchases.subscriptions; | 4689 api.PurchasesSubscriptionsResourceApi res = new api.AndroidpublisherApi(mo
ck).purchases.subscriptions; |
4690 var arg_packageName = "foo"; | 4690 var arg_packageName = "foo"; |
4691 var arg_subscriptionId = "foo"; | 4691 var arg_subscriptionId = "foo"; |
4692 var arg_token = "foo"; | 4692 var arg_token = "foo"; |
4693 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 4693 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
4694 var path = (req.url).path; | 4694 var path = (req.url).path; |
4695 var pathOffset = 0; | 4695 var pathOffset = 0; |
4696 var index; | 4696 var index; |
4697 var subPart; | 4697 var subPart; |
4698 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 4698 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
4699 pathOffset += 1; | 4699 pathOffset += 1; |
4700 | 4700 |
4701 var query = (req.url).query; | 4701 var query = (req.url).query; |
4702 var queryOffset = 0; | 4702 var queryOffset = 0; |
4703 var queryMap = {}; | 4703 var queryMap = {}; |
(...skipping 11 matching lines...) Expand all Loading... |
4715 } | 4715 } |
4716 } | 4716 } |
4717 | 4717 |
4718 | 4718 |
4719 var h = { | 4719 var h = { |
4720 "content-type" : "application/json; charset=utf-8", | 4720 "content-type" : "application/json; charset=utf-8", |
4721 }; | 4721 }; |
4722 var resp = ""; | 4722 var resp = ""; |
4723 return new async.Future.value(stringResponse(200, h, resp)); | 4723 return new async.Future.value(stringResponse(200, h, resp)); |
4724 }), true); | 4724 }), true); |
4725 res.revoke(arg_packageName, arg_subscriptionId, arg_token).then(unittest.e
xpectAsync((_) {})); | 4725 res.revoke(arg_packageName, arg_subscriptionId, arg_token).then(unittest.e
xpectAsync1((_) {})); |
4726 }); | 4726 }); |
4727 | 4727 |
4728 }); | 4728 }); |
4729 | 4729 |
4730 | 4730 |
4731 unittest.group("resource-PurchasesVoidedpurchasesResourceApi", () { | 4731 unittest.group("resource-PurchasesVoidedpurchasesResourceApi", () { |
4732 unittest.test("method--list", () { | 4732 unittest.test("method--list", () { |
4733 | 4733 |
4734 var mock = new HttpServerMock(); | 4734 var mock = new HttpServerMock(); |
4735 api.PurchasesVoidedpurchasesResourceApi res = new api.AndroidpublisherApi(
mock).purchases.voidedpurchases; | 4735 api.PurchasesVoidedpurchasesResourceApi res = new api.AndroidpublisherApi(
mock).purchases.voidedpurchases; |
4736 var arg_packageName = "foo"; | 4736 var arg_packageName = "foo"; |
4737 var arg_endTime = "foo"; | 4737 var arg_endTime = "foo"; |
4738 var arg_maxResults = 42; | 4738 var arg_maxResults = 42; |
4739 var arg_startIndex = 42; | 4739 var arg_startIndex = 42; |
4740 var arg_startTime = "foo"; | 4740 var arg_startTime = "foo"; |
4741 var arg_token = "foo"; | 4741 var arg_token = "foo"; |
4742 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 4742 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
4743 var path = (req.url).path; | 4743 var path = (req.url).path; |
4744 var pathOffset = 0; | 4744 var pathOffset = 0; |
4745 var index; | 4745 var index; |
4746 var subPart; | 4746 var subPart; |
4747 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 4747 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
4748 pathOffset += 1; | 4748 pathOffset += 1; |
4749 | 4749 |
4750 var query = (req.url).query; | 4750 var query = (req.url).query; |
4751 var queryOffset = 0; | 4751 var queryOffset = 0; |
4752 var queryMap = {}; | 4752 var queryMap = {}; |
(...skipping 16 matching lines...) Expand all Loading... |
4769 unittest.expect(queryMap["startTime"].first, unittest.equals(arg_startTi
me)); | 4769 unittest.expect(queryMap["startTime"].first, unittest.equals(arg_startTi
me)); |
4770 unittest.expect(queryMap["token"].first, unittest.equals(arg_token)); | 4770 unittest.expect(queryMap["token"].first, unittest.equals(arg_token)); |
4771 | 4771 |
4772 | 4772 |
4773 var h = { | 4773 var h = { |
4774 "content-type" : "application/json; charset=utf-8", | 4774 "content-type" : "application/json; charset=utf-8", |
4775 }; | 4775 }; |
4776 var resp = convert.JSON.encode(buildVoidedPurchasesListResponse()); | 4776 var resp = convert.JSON.encode(buildVoidedPurchasesListResponse()); |
4777 return new async.Future.value(stringResponse(200, h, resp)); | 4777 return new async.Future.value(stringResponse(200, h, resp)); |
4778 }), true); | 4778 }), true); |
4779 res.list(arg_packageName, endTime: arg_endTime, maxResults: arg_maxResults
, startIndex: arg_startIndex, startTime: arg_startTime, token: arg_token).then(u
nittest.expectAsync(((api.VoidedPurchasesListResponse response) { | 4779 res.list(arg_packageName, endTime: arg_endTime, maxResults: arg_maxResults
, startIndex: arg_startIndex, startTime: arg_startTime, token: arg_token).then(u
nittest.expectAsync1(((api.VoidedPurchasesListResponse response) { |
4780 checkVoidedPurchasesListResponse(response); | 4780 checkVoidedPurchasesListResponse(response); |
4781 }))); | 4781 }))); |
4782 }); | 4782 }); |
4783 | 4783 |
4784 }); | 4784 }); |
4785 | 4785 |
4786 | 4786 |
4787 unittest.group("resource-ReviewsResourceApi", () { | 4787 unittest.group("resource-ReviewsResourceApi", () { |
4788 unittest.test("method--get", () { | 4788 unittest.test("method--get", () { |
4789 | 4789 |
4790 var mock = new HttpServerMock(); | 4790 var mock = new HttpServerMock(); |
4791 api.ReviewsResourceApi res = new api.AndroidpublisherApi(mock).reviews; | 4791 api.ReviewsResourceApi res = new api.AndroidpublisherApi(mock).reviews; |
4792 var arg_packageName = "foo"; | 4792 var arg_packageName = "foo"; |
4793 var arg_reviewId = "foo"; | 4793 var arg_reviewId = "foo"; |
4794 var arg_translationLanguage = "foo"; | 4794 var arg_translationLanguage = "foo"; |
4795 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 4795 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
4796 var path = (req.url).path; | 4796 var path = (req.url).path; |
4797 var pathOffset = 0; | 4797 var pathOffset = 0; |
4798 var index; | 4798 var index; |
4799 var subPart; | 4799 var subPart; |
4800 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 4800 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
4801 pathOffset += 1; | 4801 pathOffset += 1; |
4802 | 4802 |
4803 var query = (req.url).query; | 4803 var query = (req.url).query; |
4804 var queryOffset = 0; | 4804 var queryOffset = 0; |
4805 var queryMap = {}; | 4805 var queryMap = {}; |
(...skipping 12 matching lines...) Expand all Loading... |
4818 } | 4818 } |
4819 unittest.expect(queryMap["translationLanguage"].first, unittest.equals(a
rg_translationLanguage)); | 4819 unittest.expect(queryMap["translationLanguage"].first, unittest.equals(a
rg_translationLanguage)); |
4820 | 4820 |
4821 | 4821 |
4822 var h = { | 4822 var h = { |
4823 "content-type" : "application/json; charset=utf-8", | 4823 "content-type" : "application/json; charset=utf-8", |
4824 }; | 4824 }; |
4825 var resp = convert.JSON.encode(buildReview()); | 4825 var resp = convert.JSON.encode(buildReview()); |
4826 return new async.Future.value(stringResponse(200, h, resp)); | 4826 return new async.Future.value(stringResponse(200, h, resp)); |
4827 }), true); | 4827 }), true); |
4828 res.get(arg_packageName, arg_reviewId, translationLanguage: arg_translatio
nLanguage).then(unittest.expectAsync(((api.Review response) { | 4828 res.get(arg_packageName, arg_reviewId, translationLanguage: arg_translatio
nLanguage).then(unittest.expectAsync1(((api.Review response) { |
4829 checkReview(response); | 4829 checkReview(response); |
4830 }))); | 4830 }))); |
4831 }); | 4831 }); |
4832 | 4832 |
4833 unittest.test("method--list", () { | 4833 unittest.test("method--list", () { |
4834 | 4834 |
4835 var mock = new HttpServerMock(); | 4835 var mock = new HttpServerMock(); |
4836 api.ReviewsResourceApi res = new api.AndroidpublisherApi(mock).reviews; | 4836 api.ReviewsResourceApi res = new api.AndroidpublisherApi(mock).reviews; |
4837 var arg_packageName = "foo"; | 4837 var arg_packageName = "foo"; |
4838 var arg_maxResults = 42; | 4838 var arg_maxResults = 42; |
4839 var arg_startIndex = 42; | 4839 var arg_startIndex = 42; |
4840 var arg_token = "foo"; | 4840 var arg_token = "foo"; |
4841 var arg_translationLanguage = "foo"; | 4841 var arg_translationLanguage = "foo"; |
4842 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 4842 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
4843 var path = (req.url).path; | 4843 var path = (req.url).path; |
4844 var pathOffset = 0; | 4844 var pathOffset = 0; |
4845 var index; | 4845 var index; |
4846 var subPart; | 4846 var subPart; |
4847 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 4847 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
4848 pathOffset += 1; | 4848 pathOffset += 1; |
4849 | 4849 |
4850 var query = (req.url).query; | 4850 var query = (req.url).query; |
4851 var queryOffset = 0; | 4851 var queryOffset = 0; |
4852 var queryMap = {}; | 4852 var queryMap = {}; |
(...skipping 15 matching lines...) Expand all Loading... |
4868 unittest.expect(queryMap["token"].first, unittest.equals(arg_token)); | 4868 unittest.expect(queryMap["token"].first, unittest.equals(arg_token)); |
4869 unittest.expect(queryMap["translationLanguage"].first, unittest.equals(a
rg_translationLanguage)); | 4869 unittest.expect(queryMap["translationLanguage"].first, unittest.equals(a
rg_translationLanguage)); |
4870 | 4870 |
4871 | 4871 |
4872 var h = { | 4872 var h = { |
4873 "content-type" : "application/json; charset=utf-8", | 4873 "content-type" : "application/json; charset=utf-8", |
4874 }; | 4874 }; |
4875 var resp = convert.JSON.encode(buildReviewsListResponse()); | 4875 var resp = convert.JSON.encode(buildReviewsListResponse()); |
4876 return new async.Future.value(stringResponse(200, h, resp)); | 4876 return new async.Future.value(stringResponse(200, h, resp)); |
4877 }), true); | 4877 }), true); |
4878 res.list(arg_packageName, maxResults: arg_maxResults, startIndex: arg_star
tIndex, token: arg_token, translationLanguage: arg_translationLanguage).then(uni
ttest.expectAsync(((api.ReviewsListResponse response) { | 4878 res.list(arg_packageName, maxResults: arg_maxResults, startIndex: arg_star
tIndex, token: arg_token, translationLanguage: arg_translationLanguage).then(uni
ttest.expectAsync1(((api.ReviewsListResponse response) { |
4879 checkReviewsListResponse(response); | 4879 checkReviewsListResponse(response); |
4880 }))); | 4880 }))); |
4881 }); | 4881 }); |
4882 | 4882 |
4883 unittest.test("method--reply", () { | 4883 unittest.test("method--reply", () { |
4884 | 4884 |
4885 var mock = new HttpServerMock(); | 4885 var mock = new HttpServerMock(); |
4886 api.ReviewsResourceApi res = new api.AndroidpublisherApi(mock).reviews; | 4886 api.ReviewsResourceApi res = new api.AndroidpublisherApi(mock).reviews; |
4887 var arg_request = buildReviewsReplyRequest(); | 4887 var arg_request = buildReviewsReplyRequest(); |
4888 var arg_packageName = "foo"; | 4888 var arg_packageName = "foo"; |
4889 var arg_reviewId = "foo"; | 4889 var arg_reviewId = "foo"; |
4890 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 4890 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
4891 var obj = new api.ReviewsReplyRequest.fromJson(json); | 4891 var obj = new api.ReviewsReplyRequest.fromJson(json); |
4892 checkReviewsReplyRequest(obj); | 4892 checkReviewsReplyRequest(obj); |
4893 | 4893 |
4894 var path = (req.url).path; | 4894 var path = (req.url).path; |
4895 var pathOffset = 0; | 4895 var pathOffset = 0; |
4896 var index; | 4896 var index; |
4897 var subPart; | 4897 var subPart; |
4898 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 4898 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
4899 pathOffset += 1; | 4899 pathOffset += 1; |
4900 | 4900 |
(...skipping 14 matching lines...) Expand all Loading... |
4915 } | 4915 } |
4916 } | 4916 } |
4917 | 4917 |
4918 | 4918 |
4919 var h = { | 4919 var h = { |
4920 "content-type" : "application/json; charset=utf-8", | 4920 "content-type" : "application/json; charset=utf-8", |
4921 }; | 4921 }; |
4922 var resp = convert.JSON.encode(buildReviewsReplyResponse()); | 4922 var resp = convert.JSON.encode(buildReviewsReplyResponse()); |
4923 return new async.Future.value(stringResponse(200, h, resp)); | 4923 return new async.Future.value(stringResponse(200, h, resp)); |
4924 }), true); | 4924 }), true); |
4925 res.reply(arg_request, arg_packageName, arg_reviewId).then(unittest.expect
Async(((api.ReviewsReplyResponse response) { | 4925 res.reply(arg_request, arg_packageName, arg_reviewId).then(unittest.expect
Async1(((api.ReviewsReplyResponse response) { |
4926 checkReviewsReplyResponse(response); | 4926 checkReviewsReplyResponse(response); |
4927 }))); | 4927 }))); |
4928 }); | 4928 }); |
4929 | 4929 |
4930 }); | 4930 }); |
4931 | 4931 |
4932 | 4932 |
4933 } | 4933 } |
4934 | 4934 |
OLD | NEW |