OLD | NEW |
1 library googleapis_beta.appengine.v1beta5.test; | 1 library googleapis_beta.appengine.v1beta5.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_beta/appengine/v1beta5.dart' as api; | 12 import 'package:googleapis_beta/appengine/v1beta5.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 buildCounterApiConfigHandler = 0; | 54 core.int buildCounterApiConfigHandler = 0; |
55 buildApiConfigHandler() { | 55 buildApiConfigHandler() { |
56 var o = new api.ApiConfigHandler(); | 56 var o = new api.ApiConfigHandler(); |
57 buildCounterApiConfigHandler++; | 57 buildCounterApiConfigHandler++; |
58 if (buildCounterApiConfigHandler < 3) { | 58 if (buildCounterApiConfigHandler < 3) { |
59 o.authFailAction = "foo"; | 59 o.authFailAction = "foo"; |
(...skipping 30 matching lines...) Expand all Loading... |
90 } | 90 } |
91 | 91 |
92 checkApiEndpointHandler(api.ApiEndpointHandler o) { | 92 checkApiEndpointHandler(api.ApiEndpointHandler o) { |
93 buildCounterApiEndpointHandler++; | 93 buildCounterApiEndpointHandler++; |
94 if (buildCounterApiEndpointHandler < 3) { | 94 if (buildCounterApiEndpointHandler < 3) { |
95 unittest.expect(o.scriptPath, unittest.equals('foo')); | 95 unittest.expect(o.scriptPath, unittest.equals('foo')); |
96 } | 96 } |
97 buildCounterApiEndpointHandler--; | 97 buildCounterApiEndpointHandler--; |
98 } | 98 } |
99 | 99 |
100 buildUnnamed3867() { | 100 buildUnnamed3341() { |
101 var o = new core.List<api.UrlDispatchRule>(); | 101 var o = new core.List<api.UrlDispatchRule>(); |
102 o.add(buildUrlDispatchRule()); | 102 o.add(buildUrlDispatchRule()); |
103 o.add(buildUrlDispatchRule()); | 103 o.add(buildUrlDispatchRule()); |
104 return o; | 104 return o; |
105 } | 105 } |
106 | 106 |
107 checkUnnamed3867(core.List<api.UrlDispatchRule> o) { | 107 checkUnnamed3341(core.List<api.UrlDispatchRule> o) { |
108 unittest.expect(o, unittest.hasLength(2)); | 108 unittest.expect(o, unittest.hasLength(2)); |
109 checkUrlDispatchRule(o[0]); | 109 checkUrlDispatchRule(o[0]); |
110 checkUrlDispatchRule(o[1]); | 110 checkUrlDispatchRule(o[1]); |
111 } | 111 } |
112 | 112 |
113 core.int buildCounterApplication = 0; | 113 core.int buildCounterApplication = 0; |
114 buildApplication() { | 114 buildApplication() { |
115 var o = new api.Application(); | 115 var o = new api.Application(); |
116 buildCounterApplication++; | 116 buildCounterApplication++; |
117 if (buildCounterApplication < 3) { | 117 if (buildCounterApplication < 3) { |
118 o.authDomain = "foo"; | 118 o.authDomain = "foo"; |
119 o.codeBucket = "foo"; | 119 o.codeBucket = "foo"; |
120 o.defaultBucket = "foo"; | 120 o.defaultBucket = "foo"; |
121 o.defaultCookieExpiration = "foo"; | 121 o.defaultCookieExpiration = "foo"; |
122 o.defaultHostname = "foo"; | 122 o.defaultHostname = "foo"; |
123 o.dispatchRules = buildUnnamed3867(); | 123 o.dispatchRules = buildUnnamed3341(); |
124 o.iap = buildIdentityAwareProxy(); | 124 o.iap = buildIdentityAwareProxy(); |
125 o.id = "foo"; | 125 o.id = "foo"; |
126 o.location = "foo"; | 126 o.location = "foo"; |
127 o.name = "foo"; | 127 o.name = "foo"; |
128 } | 128 } |
129 buildCounterApplication--; | 129 buildCounterApplication--; |
130 return o; | 130 return o; |
131 } | 131 } |
132 | 132 |
133 checkApplication(api.Application o) { | 133 checkApplication(api.Application o) { |
134 buildCounterApplication++; | 134 buildCounterApplication++; |
135 if (buildCounterApplication < 3) { | 135 if (buildCounterApplication < 3) { |
136 unittest.expect(o.authDomain, unittest.equals('foo')); | 136 unittest.expect(o.authDomain, unittest.equals('foo')); |
137 unittest.expect(o.codeBucket, unittest.equals('foo')); | 137 unittest.expect(o.codeBucket, unittest.equals('foo')); |
138 unittest.expect(o.defaultBucket, unittest.equals('foo')); | 138 unittest.expect(o.defaultBucket, unittest.equals('foo')); |
139 unittest.expect(o.defaultCookieExpiration, unittest.equals('foo')); | 139 unittest.expect(o.defaultCookieExpiration, unittest.equals('foo')); |
140 unittest.expect(o.defaultHostname, unittest.equals('foo')); | 140 unittest.expect(o.defaultHostname, unittest.equals('foo')); |
141 checkUnnamed3867(o.dispatchRules); | 141 checkUnnamed3341(o.dispatchRules); |
142 checkIdentityAwareProxy(o.iap); | 142 checkIdentityAwareProxy(o.iap); |
143 unittest.expect(o.id, unittest.equals('foo')); | 143 unittest.expect(o.id, unittest.equals('foo')); |
144 unittest.expect(o.location, unittest.equals('foo')); | 144 unittest.expect(o.location, unittest.equals('foo')); |
145 unittest.expect(o.name, unittest.equals('foo')); | 145 unittest.expect(o.name, unittest.equals('foo')); |
146 } | 146 } |
147 buildCounterApplication--; | 147 buildCounterApplication--; |
148 } | 148 } |
149 | 149 |
150 core.int buildCounterAutomaticScaling = 0; | 150 core.int buildCounterAutomaticScaling = 0; |
151 buildAutomaticScaling() { | 151 buildAutomaticScaling() { |
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
261 } | 261 } |
262 | 262 |
263 checkDebugInstanceRequest(api.DebugInstanceRequest o) { | 263 checkDebugInstanceRequest(api.DebugInstanceRequest o) { |
264 buildCounterDebugInstanceRequest++; | 264 buildCounterDebugInstanceRequest++; |
265 if (buildCounterDebugInstanceRequest < 3) { | 265 if (buildCounterDebugInstanceRequest < 3) { |
266 unittest.expect(o.sshKey, unittest.equals('foo')); | 266 unittest.expect(o.sshKey, unittest.equals('foo')); |
267 } | 267 } |
268 buildCounterDebugInstanceRequest--; | 268 buildCounterDebugInstanceRequest--; |
269 } | 269 } |
270 | 270 |
271 buildUnnamed3868() { | 271 buildUnnamed3342() { |
272 var o = new core.Map<core.String, api.FileInfo>(); | 272 var o = new core.Map<core.String, api.FileInfo>(); |
273 o["x"] = buildFileInfo(); | 273 o["x"] = buildFileInfo(); |
274 o["y"] = buildFileInfo(); | 274 o["y"] = buildFileInfo(); |
275 return o; | 275 return o; |
276 } | 276 } |
277 | 277 |
278 checkUnnamed3868(core.Map<core.String, api.FileInfo> o) { | 278 checkUnnamed3342(core.Map<core.String, api.FileInfo> o) { |
279 unittest.expect(o, unittest.hasLength(2)); | 279 unittest.expect(o, unittest.hasLength(2)); |
280 checkFileInfo(o["x"]); | 280 checkFileInfo(o["x"]); |
281 checkFileInfo(o["y"]); | 281 checkFileInfo(o["y"]); |
282 } | 282 } |
283 | 283 |
284 buildUnnamed3869() { | 284 buildUnnamed3343() { |
285 var o = new core.List<api.SourceReference>(); | 285 var o = new core.List<api.SourceReference>(); |
286 o.add(buildSourceReference()); | 286 o.add(buildSourceReference()); |
287 o.add(buildSourceReference()); | 287 o.add(buildSourceReference()); |
288 return o; | 288 return o; |
289 } | 289 } |
290 | 290 |
291 checkUnnamed3869(core.List<api.SourceReference> o) { | 291 checkUnnamed3343(core.List<api.SourceReference> o) { |
292 unittest.expect(o, unittest.hasLength(2)); | 292 unittest.expect(o, unittest.hasLength(2)); |
293 checkSourceReference(o[0]); | 293 checkSourceReference(o[0]); |
294 checkSourceReference(o[1]); | 294 checkSourceReference(o[1]); |
295 } | 295 } |
296 | 296 |
297 core.int buildCounterDeployment = 0; | 297 core.int buildCounterDeployment = 0; |
298 buildDeployment() { | 298 buildDeployment() { |
299 var o = new api.Deployment(); | 299 var o = new api.Deployment(); |
300 buildCounterDeployment++; | 300 buildCounterDeployment++; |
301 if (buildCounterDeployment < 3) { | 301 if (buildCounterDeployment < 3) { |
302 o.container = buildContainerInfo(); | 302 o.container = buildContainerInfo(); |
303 o.files = buildUnnamed3868(); | 303 o.files = buildUnnamed3342(); |
304 o.sourceReferences = buildUnnamed3869(); | 304 o.sourceReferences = buildUnnamed3343(); |
305 } | 305 } |
306 buildCounterDeployment--; | 306 buildCounterDeployment--; |
307 return o; | 307 return o; |
308 } | 308 } |
309 | 309 |
310 checkDeployment(api.Deployment o) { | 310 checkDeployment(api.Deployment o) { |
311 buildCounterDeployment++; | 311 buildCounterDeployment++; |
312 if (buildCounterDeployment < 3) { | 312 if (buildCounterDeployment < 3) { |
313 checkContainerInfo(o.container); | 313 checkContainerInfo(o.container); |
314 checkUnnamed3868(o.files); | 314 checkUnnamed3342(o.files); |
315 checkUnnamed3869(o.sourceReferences); | 315 checkUnnamed3343(o.sourceReferences); |
316 } | 316 } |
317 buildCounterDeployment--; | 317 buildCounterDeployment--; |
318 } | 318 } |
319 | 319 |
320 core.int buildCounterDiskUtilization = 0; | 320 core.int buildCounterDiskUtilization = 0; |
321 buildDiskUtilization() { | 321 buildDiskUtilization() { |
322 var o = new api.DiskUtilization(); | 322 var o = new api.DiskUtilization(); |
323 buildCounterDiskUtilization++; | 323 buildCounterDiskUtilization++; |
324 if (buildCounterDiskUtilization < 3) { | 324 if (buildCounterDiskUtilization < 3) { |
325 o.targetReadBytesPerSec = 42; | 325 o.targetReadBytesPerSec = 42; |
(...skipping 202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
528 | 528 |
529 checkLibrary(api.Library o) { | 529 checkLibrary(api.Library o) { |
530 buildCounterLibrary++; | 530 buildCounterLibrary++; |
531 if (buildCounterLibrary < 3) { | 531 if (buildCounterLibrary < 3) { |
532 unittest.expect(o.name, unittest.equals('foo')); | 532 unittest.expect(o.name, unittest.equals('foo')); |
533 unittest.expect(o.version, unittest.equals('foo')); | 533 unittest.expect(o.version, unittest.equals('foo')); |
534 } | 534 } |
535 buildCounterLibrary--; | 535 buildCounterLibrary--; |
536 } | 536 } |
537 | 537 |
538 buildUnnamed3870() { | 538 buildUnnamed3344() { |
539 var o = new core.List<api.Instance>(); | 539 var o = new core.List<api.Instance>(); |
540 o.add(buildInstance()); | 540 o.add(buildInstance()); |
541 o.add(buildInstance()); | 541 o.add(buildInstance()); |
542 return o; | 542 return o; |
543 } | 543 } |
544 | 544 |
545 checkUnnamed3870(core.List<api.Instance> o) { | 545 checkUnnamed3344(core.List<api.Instance> o) { |
546 unittest.expect(o, unittest.hasLength(2)); | 546 unittest.expect(o, unittest.hasLength(2)); |
547 checkInstance(o[0]); | 547 checkInstance(o[0]); |
548 checkInstance(o[1]); | 548 checkInstance(o[1]); |
549 } | 549 } |
550 | 550 |
551 core.int buildCounterListInstancesResponse = 0; | 551 core.int buildCounterListInstancesResponse = 0; |
552 buildListInstancesResponse() { | 552 buildListInstancesResponse() { |
553 var o = new api.ListInstancesResponse(); | 553 var o = new api.ListInstancesResponse(); |
554 buildCounterListInstancesResponse++; | 554 buildCounterListInstancesResponse++; |
555 if (buildCounterListInstancesResponse < 3) { | 555 if (buildCounterListInstancesResponse < 3) { |
556 o.instances = buildUnnamed3870(); | 556 o.instances = buildUnnamed3344(); |
557 o.nextPageToken = "foo"; | 557 o.nextPageToken = "foo"; |
558 } | 558 } |
559 buildCounterListInstancesResponse--; | 559 buildCounterListInstancesResponse--; |
560 return o; | 560 return o; |
561 } | 561 } |
562 | 562 |
563 checkListInstancesResponse(api.ListInstancesResponse o) { | 563 checkListInstancesResponse(api.ListInstancesResponse o) { |
564 buildCounterListInstancesResponse++; | 564 buildCounterListInstancesResponse++; |
565 if (buildCounterListInstancesResponse < 3) { | 565 if (buildCounterListInstancesResponse < 3) { |
566 checkUnnamed3870(o.instances); | 566 checkUnnamed3344(o.instances); |
567 unittest.expect(o.nextPageToken, unittest.equals('foo')); | 567 unittest.expect(o.nextPageToken, unittest.equals('foo')); |
568 } | 568 } |
569 buildCounterListInstancesResponse--; | 569 buildCounterListInstancesResponse--; |
570 } | 570 } |
571 | 571 |
572 buildUnnamed3871() { | 572 buildUnnamed3345() { |
573 var o = new core.List<api.Location>(); | 573 var o = new core.List<api.Location>(); |
574 o.add(buildLocation()); | 574 o.add(buildLocation()); |
575 o.add(buildLocation()); | 575 o.add(buildLocation()); |
576 return o; | 576 return o; |
577 } | 577 } |
578 | 578 |
579 checkUnnamed3871(core.List<api.Location> o) { | 579 checkUnnamed3345(core.List<api.Location> o) { |
580 unittest.expect(o, unittest.hasLength(2)); | 580 unittest.expect(o, unittest.hasLength(2)); |
581 checkLocation(o[0]); | 581 checkLocation(o[0]); |
582 checkLocation(o[1]); | 582 checkLocation(o[1]); |
583 } | 583 } |
584 | 584 |
585 core.int buildCounterListLocationsResponse = 0; | 585 core.int buildCounterListLocationsResponse = 0; |
586 buildListLocationsResponse() { | 586 buildListLocationsResponse() { |
587 var o = new api.ListLocationsResponse(); | 587 var o = new api.ListLocationsResponse(); |
588 buildCounterListLocationsResponse++; | 588 buildCounterListLocationsResponse++; |
589 if (buildCounterListLocationsResponse < 3) { | 589 if (buildCounterListLocationsResponse < 3) { |
590 o.locations = buildUnnamed3871(); | 590 o.locations = buildUnnamed3345(); |
591 o.nextPageToken = "foo"; | 591 o.nextPageToken = "foo"; |
592 } | 592 } |
593 buildCounterListLocationsResponse--; | 593 buildCounterListLocationsResponse--; |
594 return o; | 594 return o; |
595 } | 595 } |
596 | 596 |
597 checkListLocationsResponse(api.ListLocationsResponse o) { | 597 checkListLocationsResponse(api.ListLocationsResponse o) { |
598 buildCounterListLocationsResponse++; | 598 buildCounterListLocationsResponse++; |
599 if (buildCounterListLocationsResponse < 3) { | 599 if (buildCounterListLocationsResponse < 3) { |
600 checkUnnamed3871(o.locations); | 600 checkUnnamed3345(o.locations); |
601 unittest.expect(o.nextPageToken, unittest.equals('foo')); | 601 unittest.expect(o.nextPageToken, unittest.equals('foo')); |
602 } | 602 } |
603 buildCounterListLocationsResponse--; | 603 buildCounterListLocationsResponse--; |
604 } | 604 } |
605 | 605 |
606 buildUnnamed3872() { | 606 buildUnnamed3346() { |
607 var o = new core.List<api.Operation>(); | 607 var o = new core.List<api.Operation>(); |
608 o.add(buildOperation()); | 608 o.add(buildOperation()); |
609 o.add(buildOperation()); | 609 o.add(buildOperation()); |
610 return o; | 610 return o; |
611 } | 611 } |
612 | 612 |
613 checkUnnamed3872(core.List<api.Operation> o) { | 613 checkUnnamed3346(core.List<api.Operation> o) { |
614 unittest.expect(o, unittest.hasLength(2)); | 614 unittest.expect(o, unittest.hasLength(2)); |
615 checkOperation(o[0]); | 615 checkOperation(o[0]); |
616 checkOperation(o[1]); | 616 checkOperation(o[1]); |
617 } | 617 } |
618 | 618 |
619 core.int buildCounterListOperationsResponse = 0; | 619 core.int buildCounterListOperationsResponse = 0; |
620 buildListOperationsResponse() { | 620 buildListOperationsResponse() { |
621 var o = new api.ListOperationsResponse(); | 621 var o = new api.ListOperationsResponse(); |
622 buildCounterListOperationsResponse++; | 622 buildCounterListOperationsResponse++; |
623 if (buildCounterListOperationsResponse < 3) { | 623 if (buildCounterListOperationsResponse < 3) { |
624 o.nextPageToken = "foo"; | 624 o.nextPageToken = "foo"; |
625 o.operations = buildUnnamed3872(); | 625 o.operations = buildUnnamed3346(); |
626 } | 626 } |
627 buildCounterListOperationsResponse--; | 627 buildCounterListOperationsResponse--; |
628 return o; | 628 return o; |
629 } | 629 } |
630 | 630 |
631 checkListOperationsResponse(api.ListOperationsResponse o) { | 631 checkListOperationsResponse(api.ListOperationsResponse o) { |
632 buildCounterListOperationsResponse++; | 632 buildCounterListOperationsResponse++; |
633 if (buildCounterListOperationsResponse < 3) { | 633 if (buildCounterListOperationsResponse < 3) { |
634 unittest.expect(o.nextPageToken, unittest.equals('foo')); | 634 unittest.expect(o.nextPageToken, unittest.equals('foo')); |
635 checkUnnamed3872(o.operations); | 635 checkUnnamed3346(o.operations); |
636 } | 636 } |
637 buildCounterListOperationsResponse--; | 637 buildCounterListOperationsResponse--; |
638 } | 638 } |
639 | 639 |
640 buildUnnamed3873() { | 640 buildUnnamed3347() { |
641 var o = new core.List<api.Service>(); | 641 var o = new core.List<api.Service>(); |
642 o.add(buildService()); | 642 o.add(buildService()); |
643 o.add(buildService()); | 643 o.add(buildService()); |
644 return o; | 644 return o; |
645 } | 645 } |
646 | 646 |
647 checkUnnamed3873(core.List<api.Service> o) { | 647 checkUnnamed3347(core.List<api.Service> o) { |
648 unittest.expect(o, unittest.hasLength(2)); | 648 unittest.expect(o, unittest.hasLength(2)); |
649 checkService(o[0]); | 649 checkService(o[0]); |
650 checkService(o[1]); | 650 checkService(o[1]); |
651 } | 651 } |
652 | 652 |
653 core.int buildCounterListServicesResponse = 0; | 653 core.int buildCounterListServicesResponse = 0; |
654 buildListServicesResponse() { | 654 buildListServicesResponse() { |
655 var o = new api.ListServicesResponse(); | 655 var o = new api.ListServicesResponse(); |
656 buildCounterListServicesResponse++; | 656 buildCounterListServicesResponse++; |
657 if (buildCounterListServicesResponse < 3) { | 657 if (buildCounterListServicesResponse < 3) { |
658 o.nextPageToken = "foo"; | 658 o.nextPageToken = "foo"; |
659 o.services = buildUnnamed3873(); | 659 o.services = buildUnnamed3347(); |
660 } | 660 } |
661 buildCounterListServicesResponse--; | 661 buildCounterListServicesResponse--; |
662 return o; | 662 return o; |
663 } | 663 } |
664 | 664 |
665 checkListServicesResponse(api.ListServicesResponse o) { | 665 checkListServicesResponse(api.ListServicesResponse o) { |
666 buildCounterListServicesResponse++; | 666 buildCounterListServicesResponse++; |
667 if (buildCounterListServicesResponse < 3) { | 667 if (buildCounterListServicesResponse < 3) { |
668 unittest.expect(o.nextPageToken, unittest.equals('foo')); | 668 unittest.expect(o.nextPageToken, unittest.equals('foo')); |
669 checkUnnamed3873(o.services); | 669 checkUnnamed3347(o.services); |
670 } | 670 } |
671 buildCounterListServicesResponse--; | 671 buildCounterListServicesResponse--; |
672 } | 672 } |
673 | 673 |
674 buildUnnamed3874() { | 674 buildUnnamed3348() { |
675 var o = new core.List<api.Version>(); | 675 var o = new core.List<api.Version>(); |
676 o.add(buildVersion()); | 676 o.add(buildVersion()); |
677 o.add(buildVersion()); | 677 o.add(buildVersion()); |
678 return o; | 678 return o; |
679 } | 679 } |
680 | 680 |
681 checkUnnamed3874(core.List<api.Version> o) { | 681 checkUnnamed3348(core.List<api.Version> o) { |
682 unittest.expect(o, unittest.hasLength(2)); | 682 unittest.expect(o, unittest.hasLength(2)); |
683 checkVersion(o[0]); | 683 checkVersion(o[0]); |
684 checkVersion(o[1]); | 684 checkVersion(o[1]); |
685 } | 685 } |
686 | 686 |
687 core.int buildCounterListVersionsResponse = 0; | 687 core.int buildCounterListVersionsResponse = 0; |
688 buildListVersionsResponse() { | 688 buildListVersionsResponse() { |
689 var o = new api.ListVersionsResponse(); | 689 var o = new api.ListVersionsResponse(); |
690 buildCounterListVersionsResponse++; | 690 buildCounterListVersionsResponse++; |
691 if (buildCounterListVersionsResponse < 3) { | 691 if (buildCounterListVersionsResponse < 3) { |
692 o.nextPageToken = "foo"; | 692 o.nextPageToken = "foo"; |
693 o.versions = buildUnnamed3874(); | 693 o.versions = buildUnnamed3348(); |
694 } | 694 } |
695 buildCounterListVersionsResponse--; | 695 buildCounterListVersionsResponse--; |
696 return o; | 696 return o; |
697 } | 697 } |
698 | 698 |
699 checkListVersionsResponse(api.ListVersionsResponse o) { | 699 checkListVersionsResponse(api.ListVersionsResponse o) { |
700 buildCounterListVersionsResponse++; | 700 buildCounterListVersionsResponse++; |
701 if (buildCounterListVersionsResponse < 3) { | 701 if (buildCounterListVersionsResponse < 3) { |
702 unittest.expect(o.nextPageToken, unittest.equals('foo')); | 702 unittest.expect(o.nextPageToken, unittest.equals('foo')); |
703 checkUnnamed3874(o.versions); | 703 checkUnnamed3348(o.versions); |
704 } | 704 } |
705 buildCounterListVersionsResponse--; | 705 buildCounterListVersionsResponse--; |
706 } | 706 } |
707 | 707 |
708 buildUnnamed3875() { | 708 buildUnnamed3349() { |
709 var o = new core.Map<core.String, core.String>(); | 709 var o = new core.Map<core.String, core.String>(); |
710 o["x"] = "foo"; | 710 o["x"] = "foo"; |
711 o["y"] = "foo"; | 711 o["y"] = "foo"; |
712 return o; | 712 return o; |
713 } | 713 } |
714 | 714 |
715 checkUnnamed3875(core.Map<core.String, core.String> o) { | 715 checkUnnamed3349(core.Map<core.String, core.String> o) { |
716 unittest.expect(o, unittest.hasLength(2)); | 716 unittest.expect(o, unittest.hasLength(2)); |
717 unittest.expect(o["x"], unittest.equals('foo')); | 717 unittest.expect(o["x"], unittest.equals('foo')); |
718 unittest.expect(o["y"], unittest.equals('foo')); | 718 unittest.expect(o["y"], unittest.equals('foo')); |
719 } | 719 } |
720 | 720 |
721 buildUnnamed3876() { | 721 buildUnnamed3350() { |
722 var o = new core.Map<core.String, core.Object>(); | 722 var o = new core.Map<core.String, core.Object>(); |
723 o["x"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; | 723 o["x"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; |
724 o["y"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; | 724 o["y"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; |
725 return o; | 725 return o; |
726 } | 726 } |
727 | 727 |
728 checkUnnamed3876(core.Map<core.String, core.Object> o) { | 728 checkUnnamed3350(core.Map<core.String, core.Object> o) { |
729 unittest.expect(o, unittest.hasLength(2)); | 729 unittest.expect(o, unittest.hasLength(2)); |
730 var casted1 = (o["x"]) as core.Map; unittest.expect(casted1, unittest.hasLengt
h(3)); unittest.expect(casted1["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted1["bool"], unittest.equals(true)); unittest.expect(casted1["string"],
unittest.equals('foo')); | 730 var casted1 = (o["x"]) as core.Map; unittest.expect(casted1, unittest.hasLengt
h(3)); unittest.expect(casted1["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted1["bool"], unittest.equals(true)); unittest.expect(casted1["string"],
unittest.equals('foo')); |
731 var casted2 = (o["y"]) as core.Map; unittest.expect(casted2, unittest.hasLengt
h(3)); unittest.expect(casted2["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted2["bool"], unittest.equals(true)); unittest.expect(casted2["string"],
unittest.equals('foo')); | 731 var casted2 = (o["y"]) as core.Map; unittest.expect(casted2, unittest.hasLengt
h(3)); unittest.expect(casted2["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted2["bool"], unittest.equals(true)); unittest.expect(casted2["string"],
unittest.equals('foo')); |
732 } | 732 } |
733 | 733 |
734 core.int buildCounterLocation = 0; | 734 core.int buildCounterLocation = 0; |
735 buildLocation() { | 735 buildLocation() { |
736 var o = new api.Location(); | 736 var o = new api.Location(); |
737 buildCounterLocation++; | 737 buildCounterLocation++; |
738 if (buildCounterLocation < 3) { | 738 if (buildCounterLocation < 3) { |
739 o.labels = buildUnnamed3875(); | 739 o.labels = buildUnnamed3349(); |
740 o.locationId = "foo"; | 740 o.locationId = "foo"; |
741 o.metadata = buildUnnamed3876(); | 741 o.metadata = buildUnnamed3350(); |
742 o.name = "foo"; | 742 o.name = "foo"; |
743 } | 743 } |
744 buildCounterLocation--; | 744 buildCounterLocation--; |
745 return o; | 745 return o; |
746 } | 746 } |
747 | 747 |
748 checkLocation(api.Location o) { | 748 checkLocation(api.Location o) { |
749 buildCounterLocation++; | 749 buildCounterLocation++; |
750 if (buildCounterLocation < 3) { | 750 if (buildCounterLocation < 3) { |
751 checkUnnamed3875(o.labels); | 751 checkUnnamed3349(o.labels); |
752 unittest.expect(o.locationId, unittest.equals('foo')); | 752 unittest.expect(o.locationId, unittest.equals('foo')); |
753 checkUnnamed3876(o.metadata); | 753 checkUnnamed3350(o.metadata); |
754 unittest.expect(o.name, unittest.equals('foo')); | 754 unittest.expect(o.name, unittest.equals('foo')); |
755 } | 755 } |
756 buildCounterLocation--; | 756 buildCounterLocation--; |
757 } | 757 } |
758 | 758 |
759 core.int buildCounterLocationMetadata = 0; | 759 core.int buildCounterLocationMetadata = 0; |
760 buildLocationMetadata() { | 760 buildLocationMetadata() { |
761 var o = new api.LocationMetadata(); | 761 var o = new api.LocationMetadata(); |
762 buildCounterLocationMetadata++; | 762 buildCounterLocationMetadata++; |
763 if (buildCounterLocationMetadata < 3) { | 763 if (buildCounterLocationMetadata < 3) { |
(...skipping 25 matching lines...) Expand all Loading... |
789 } | 789 } |
790 | 790 |
791 checkManualScaling(api.ManualScaling o) { | 791 checkManualScaling(api.ManualScaling o) { |
792 buildCounterManualScaling++; | 792 buildCounterManualScaling++; |
793 if (buildCounterManualScaling < 3) { | 793 if (buildCounterManualScaling < 3) { |
794 unittest.expect(o.instances, unittest.equals(42)); | 794 unittest.expect(o.instances, unittest.equals(42)); |
795 } | 795 } |
796 buildCounterManualScaling--; | 796 buildCounterManualScaling--; |
797 } | 797 } |
798 | 798 |
799 buildUnnamed3877() { | 799 buildUnnamed3351() { |
800 var o = new core.List<core.String>(); | 800 var o = new core.List<core.String>(); |
801 o.add("foo"); | 801 o.add("foo"); |
802 o.add("foo"); | 802 o.add("foo"); |
803 return o; | 803 return o; |
804 } | 804 } |
805 | 805 |
806 checkUnnamed3877(core.List<core.String> o) { | 806 checkUnnamed3351(core.List<core.String> o) { |
807 unittest.expect(o, unittest.hasLength(2)); | 807 unittest.expect(o, unittest.hasLength(2)); |
808 unittest.expect(o[0], unittest.equals('foo')); | 808 unittest.expect(o[0], unittest.equals('foo')); |
809 unittest.expect(o[1], unittest.equals('foo')); | 809 unittest.expect(o[1], unittest.equals('foo')); |
810 } | 810 } |
811 | 811 |
812 core.int buildCounterNetwork = 0; | 812 core.int buildCounterNetwork = 0; |
813 buildNetwork() { | 813 buildNetwork() { |
814 var o = new api.Network(); | 814 var o = new api.Network(); |
815 buildCounterNetwork++; | 815 buildCounterNetwork++; |
816 if (buildCounterNetwork < 3) { | 816 if (buildCounterNetwork < 3) { |
817 o.forwardedPorts = buildUnnamed3877(); | 817 o.forwardedPorts = buildUnnamed3351(); |
818 o.instanceTag = "foo"; | 818 o.instanceTag = "foo"; |
819 o.name = "foo"; | 819 o.name = "foo"; |
820 o.subnetworkName = "foo"; | 820 o.subnetworkName = "foo"; |
821 } | 821 } |
822 buildCounterNetwork--; | 822 buildCounterNetwork--; |
823 return o; | 823 return o; |
824 } | 824 } |
825 | 825 |
826 checkNetwork(api.Network o) { | 826 checkNetwork(api.Network o) { |
827 buildCounterNetwork++; | 827 buildCounterNetwork++; |
828 if (buildCounterNetwork < 3) { | 828 if (buildCounterNetwork < 3) { |
829 checkUnnamed3877(o.forwardedPorts); | 829 checkUnnamed3351(o.forwardedPorts); |
830 unittest.expect(o.instanceTag, unittest.equals('foo')); | 830 unittest.expect(o.instanceTag, unittest.equals('foo')); |
831 unittest.expect(o.name, unittest.equals('foo')); | 831 unittest.expect(o.name, unittest.equals('foo')); |
832 unittest.expect(o.subnetworkName, unittest.equals('foo')); | 832 unittest.expect(o.subnetworkName, unittest.equals('foo')); |
833 } | 833 } |
834 buildCounterNetwork--; | 834 buildCounterNetwork--; |
835 } | 835 } |
836 | 836 |
837 core.int buildCounterNetworkUtilization = 0; | 837 core.int buildCounterNetworkUtilization = 0; |
838 buildNetworkUtilization() { | 838 buildNetworkUtilization() { |
839 var o = new api.NetworkUtilization(); | 839 var o = new api.NetworkUtilization(); |
(...skipping 12 matching lines...) Expand all Loading... |
852 buildCounterNetworkUtilization++; | 852 buildCounterNetworkUtilization++; |
853 if (buildCounterNetworkUtilization < 3) { | 853 if (buildCounterNetworkUtilization < 3) { |
854 unittest.expect(o.targetReceivedBytesPerSec, unittest.equals(42)); | 854 unittest.expect(o.targetReceivedBytesPerSec, unittest.equals(42)); |
855 unittest.expect(o.targetReceivedPacketsPerSec, unittest.equals(42)); | 855 unittest.expect(o.targetReceivedPacketsPerSec, unittest.equals(42)); |
856 unittest.expect(o.targetSentBytesPerSec, unittest.equals(42)); | 856 unittest.expect(o.targetSentBytesPerSec, unittest.equals(42)); |
857 unittest.expect(o.targetSentPacketsPerSec, unittest.equals(42)); | 857 unittest.expect(o.targetSentPacketsPerSec, unittest.equals(42)); |
858 } | 858 } |
859 buildCounterNetworkUtilization--; | 859 buildCounterNetworkUtilization--; |
860 } | 860 } |
861 | 861 |
862 buildUnnamed3878() { | 862 buildUnnamed3352() { |
863 var o = new core.Map<core.String, core.Object>(); | 863 var o = new core.Map<core.String, core.Object>(); |
864 o["x"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; | 864 o["x"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; |
865 o["y"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; | 865 o["y"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; |
866 return o; | 866 return o; |
867 } | 867 } |
868 | 868 |
869 checkUnnamed3878(core.Map<core.String, core.Object> o) { | 869 checkUnnamed3352(core.Map<core.String, core.Object> o) { |
870 unittest.expect(o, unittest.hasLength(2)); | 870 unittest.expect(o, unittest.hasLength(2)); |
871 var casted3 = (o["x"]) as core.Map; unittest.expect(casted3, unittest.hasLengt
h(3)); unittest.expect(casted3["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted3["bool"], unittest.equals(true)); unittest.expect(casted3["string"],
unittest.equals('foo')); | 871 var casted3 = (o["x"]) as core.Map; unittest.expect(casted3, unittest.hasLengt
h(3)); unittest.expect(casted3["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted3["bool"], unittest.equals(true)); unittest.expect(casted3["string"],
unittest.equals('foo')); |
872 var casted4 = (o["y"]) as core.Map; unittest.expect(casted4, unittest.hasLengt
h(3)); unittest.expect(casted4["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted4["bool"], unittest.equals(true)); unittest.expect(casted4["string"],
unittest.equals('foo')); | 872 var casted4 = (o["y"]) as core.Map; unittest.expect(casted4, unittest.hasLengt
h(3)); unittest.expect(casted4["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted4["bool"], unittest.equals(true)); unittest.expect(casted4["string"],
unittest.equals('foo')); |
873 } | 873 } |
874 | 874 |
875 buildUnnamed3879() { | 875 buildUnnamed3353() { |
876 var o = new core.Map<core.String, core.Object>(); | 876 var o = new core.Map<core.String, core.Object>(); |
877 o["x"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; | 877 o["x"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; |
878 o["y"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; | 878 o["y"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; |
879 return o; | 879 return o; |
880 } | 880 } |
881 | 881 |
882 checkUnnamed3879(core.Map<core.String, core.Object> o) { | 882 checkUnnamed3353(core.Map<core.String, core.Object> o) { |
883 unittest.expect(o, unittest.hasLength(2)); | 883 unittest.expect(o, unittest.hasLength(2)); |
884 var casted5 = (o["x"]) as core.Map; unittest.expect(casted5, unittest.hasLengt
h(3)); unittest.expect(casted5["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted5["bool"], unittest.equals(true)); unittest.expect(casted5["string"],
unittest.equals('foo')); | 884 var casted5 = (o["x"]) as core.Map; unittest.expect(casted5, unittest.hasLengt
h(3)); unittest.expect(casted5["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted5["bool"], unittest.equals(true)); unittest.expect(casted5["string"],
unittest.equals('foo')); |
885 var casted6 = (o["y"]) as core.Map; unittest.expect(casted6, unittest.hasLengt
h(3)); unittest.expect(casted6["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted6["bool"], unittest.equals(true)); unittest.expect(casted6["string"],
unittest.equals('foo')); | 885 var casted6 = (o["y"]) as core.Map; unittest.expect(casted6, unittest.hasLengt
h(3)); unittest.expect(casted6["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted6["bool"], unittest.equals(true)); unittest.expect(casted6["string"],
unittest.equals('foo')); |
886 } | 886 } |
887 | 887 |
888 core.int buildCounterOperation = 0; | 888 core.int buildCounterOperation = 0; |
889 buildOperation() { | 889 buildOperation() { |
890 var o = new api.Operation(); | 890 var o = new api.Operation(); |
891 buildCounterOperation++; | 891 buildCounterOperation++; |
892 if (buildCounterOperation < 3) { | 892 if (buildCounterOperation < 3) { |
893 o.done = true; | 893 o.done = true; |
894 o.error = buildStatus(); | 894 o.error = buildStatus(); |
895 o.metadata = buildUnnamed3878(); | 895 o.metadata = buildUnnamed3352(); |
896 o.name = "foo"; | 896 o.name = "foo"; |
897 o.response = buildUnnamed3879(); | 897 o.response = buildUnnamed3353(); |
898 } | 898 } |
899 buildCounterOperation--; | 899 buildCounterOperation--; |
900 return o; | 900 return o; |
901 } | 901 } |
902 | 902 |
903 checkOperation(api.Operation o) { | 903 checkOperation(api.Operation o) { |
904 buildCounterOperation++; | 904 buildCounterOperation++; |
905 if (buildCounterOperation < 3) { | 905 if (buildCounterOperation < 3) { |
906 unittest.expect(o.done, unittest.isTrue); | 906 unittest.expect(o.done, unittest.isTrue); |
907 checkStatus(o.error); | 907 checkStatus(o.error); |
908 checkUnnamed3878(o.metadata); | 908 checkUnnamed3352(o.metadata); |
909 unittest.expect(o.name, unittest.equals('foo')); | 909 unittest.expect(o.name, unittest.equals('foo')); |
910 checkUnnamed3879(o.response); | 910 checkUnnamed3353(o.response); |
911 } | 911 } |
912 buildCounterOperation--; | 912 buildCounterOperation--; |
913 } | 913 } |
914 | 914 |
915 core.int buildCounterOperationMetadata = 0; | 915 core.int buildCounterOperationMetadata = 0; |
916 buildOperationMetadata() { | 916 buildOperationMetadata() { |
917 var o = new api.OperationMetadata(); | 917 var o = new api.OperationMetadata(); |
918 buildCounterOperationMetadata++; | 918 buildCounterOperationMetadata++; |
919 if (buildCounterOperationMetadata < 3) { | 919 if (buildCounterOperationMetadata < 3) { |
920 o.endTime = "foo"; | 920 o.endTime = "foo"; |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
961 if (buildCounterOperationMetadataExperimental < 3) { | 961 if (buildCounterOperationMetadataExperimental < 3) { |
962 unittest.expect(o.endTime, unittest.equals('foo')); | 962 unittest.expect(o.endTime, unittest.equals('foo')); |
963 unittest.expect(o.insertTime, unittest.equals('foo')); | 963 unittest.expect(o.insertTime, unittest.equals('foo')); |
964 unittest.expect(o.method, unittest.equals('foo')); | 964 unittest.expect(o.method, unittest.equals('foo')); |
965 unittest.expect(o.target, unittest.equals('foo')); | 965 unittest.expect(o.target, unittest.equals('foo')); |
966 unittest.expect(o.user, unittest.equals('foo')); | 966 unittest.expect(o.user, unittest.equals('foo')); |
967 } | 967 } |
968 buildCounterOperationMetadataExperimental--; | 968 buildCounterOperationMetadataExperimental--; |
969 } | 969 } |
970 | 970 |
971 buildUnnamed3880() { | 971 buildUnnamed3354() { |
972 var o = new core.List<core.String>(); | 972 var o = new core.List<core.String>(); |
973 o.add("foo"); | 973 o.add("foo"); |
974 o.add("foo"); | 974 o.add("foo"); |
975 return o; | 975 return o; |
976 } | 976 } |
977 | 977 |
978 checkUnnamed3880(core.List<core.String> o) { | 978 checkUnnamed3354(core.List<core.String> o) { |
979 unittest.expect(o, unittest.hasLength(2)); | 979 unittest.expect(o, unittest.hasLength(2)); |
980 unittest.expect(o[0], unittest.equals('foo')); | 980 unittest.expect(o[0], unittest.equals('foo')); |
981 unittest.expect(o[1], unittest.equals('foo')); | 981 unittest.expect(o[1], unittest.equals('foo')); |
982 } | 982 } |
983 | 983 |
984 core.int buildCounterOperationMetadataV1 = 0; | 984 core.int buildCounterOperationMetadataV1 = 0; |
985 buildOperationMetadataV1() { | 985 buildOperationMetadataV1() { |
986 var o = new api.OperationMetadataV1(); | 986 var o = new api.OperationMetadataV1(); |
987 buildCounterOperationMetadataV1++; | 987 buildCounterOperationMetadataV1++; |
988 if (buildCounterOperationMetadataV1 < 3) { | 988 if (buildCounterOperationMetadataV1 < 3) { |
989 o.endTime = "foo"; | 989 o.endTime = "foo"; |
990 o.ephemeralMessage = "foo"; | 990 o.ephemeralMessage = "foo"; |
991 o.insertTime = "foo"; | 991 o.insertTime = "foo"; |
992 o.method = "foo"; | 992 o.method = "foo"; |
993 o.target = "foo"; | 993 o.target = "foo"; |
994 o.user = "foo"; | 994 o.user = "foo"; |
995 o.warning = buildUnnamed3880(); | 995 o.warning = buildUnnamed3354(); |
996 } | 996 } |
997 buildCounterOperationMetadataV1--; | 997 buildCounterOperationMetadataV1--; |
998 return o; | 998 return o; |
999 } | 999 } |
1000 | 1000 |
1001 checkOperationMetadataV1(api.OperationMetadataV1 o) { | 1001 checkOperationMetadataV1(api.OperationMetadataV1 o) { |
1002 buildCounterOperationMetadataV1++; | 1002 buildCounterOperationMetadataV1++; |
1003 if (buildCounterOperationMetadataV1 < 3) { | 1003 if (buildCounterOperationMetadataV1 < 3) { |
1004 unittest.expect(o.endTime, unittest.equals('foo')); | 1004 unittest.expect(o.endTime, unittest.equals('foo')); |
1005 unittest.expect(o.ephemeralMessage, unittest.equals('foo')); | 1005 unittest.expect(o.ephemeralMessage, unittest.equals('foo')); |
1006 unittest.expect(o.insertTime, unittest.equals('foo')); | 1006 unittest.expect(o.insertTime, unittest.equals('foo')); |
1007 unittest.expect(o.method, unittest.equals('foo')); | 1007 unittest.expect(o.method, unittest.equals('foo')); |
1008 unittest.expect(o.target, unittest.equals('foo')); | 1008 unittest.expect(o.target, unittest.equals('foo')); |
1009 unittest.expect(o.user, unittest.equals('foo')); | 1009 unittest.expect(o.user, unittest.equals('foo')); |
1010 checkUnnamed3880(o.warning); | 1010 checkUnnamed3354(o.warning); |
1011 } | 1011 } |
1012 buildCounterOperationMetadataV1--; | 1012 buildCounterOperationMetadataV1--; |
1013 } | 1013 } |
1014 | 1014 |
1015 buildUnnamed3881() { | 1015 buildUnnamed3355() { |
1016 var o = new core.List<core.String>(); | 1016 var o = new core.List<core.String>(); |
1017 o.add("foo"); | 1017 o.add("foo"); |
1018 o.add("foo"); | 1018 o.add("foo"); |
1019 return o; | 1019 return o; |
1020 } | 1020 } |
1021 | 1021 |
1022 checkUnnamed3881(core.List<core.String> o) { | 1022 checkUnnamed3355(core.List<core.String> o) { |
1023 unittest.expect(o, unittest.hasLength(2)); | 1023 unittest.expect(o, unittest.hasLength(2)); |
1024 unittest.expect(o[0], unittest.equals('foo')); | 1024 unittest.expect(o[0], unittest.equals('foo')); |
1025 unittest.expect(o[1], unittest.equals('foo')); | 1025 unittest.expect(o[1], unittest.equals('foo')); |
| 1026 } |
| 1027 |
| 1028 core.int buildCounterOperationMetadataV1Alpha = 0; |
| 1029 buildOperationMetadataV1Alpha() { |
| 1030 var o = new api.OperationMetadataV1Alpha(); |
| 1031 buildCounterOperationMetadataV1Alpha++; |
| 1032 if (buildCounterOperationMetadataV1Alpha < 3) { |
| 1033 o.endTime = "foo"; |
| 1034 o.ephemeralMessage = "foo"; |
| 1035 o.insertTime = "foo"; |
| 1036 o.method = "foo"; |
| 1037 o.target = "foo"; |
| 1038 o.user = "foo"; |
| 1039 o.warning = buildUnnamed3355(); |
| 1040 } |
| 1041 buildCounterOperationMetadataV1Alpha--; |
| 1042 return o; |
| 1043 } |
| 1044 |
| 1045 checkOperationMetadataV1Alpha(api.OperationMetadataV1Alpha o) { |
| 1046 buildCounterOperationMetadataV1Alpha++; |
| 1047 if (buildCounterOperationMetadataV1Alpha < 3) { |
| 1048 unittest.expect(o.endTime, unittest.equals('foo')); |
| 1049 unittest.expect(o.ephemeralMessage, unittest.equals('foo')); |
| 1050 unittest.expect(o.insertTime, unittest.equals('foo')); |
| 1051 unittest.expect(o.method, unittest.equals('foo')); |
| 1052 unittest.expect(o.target, unittest.equals('foo')); |
| 1053 unittest.expect(o.user, unittest.equals('foo')); |
| 1054 checkUnnamed3355(o.warning); |
| 1055 } |
| 1056 buildCounterOperationMetadataV1Alpha--; |
| 1057 } |
| 1058 |
| 1059 buildUnnamed3356() { |
| 1060 var o = new core.List<core.String>(); |
| 1061 o.add("foo"); |
| 1062 o.add("foo"); |
| 1063 return o; |
| 1064 } |
| 1065 |
| 1066 checkUnnamed3356(core.List<core.String> o) { |
| 1067 unittest.expect(o, unittest.hasLength(2)); |
| 1068 unittest.expect(o[0], unittest.equals('foo')); |
| 1069 unittest.expect(o[1], unittest.equals('foo')); |
1026 } | 1070 } |
1027 | 1071 |
1028 core.int buildCounterOperationMetadataV1Beta = 0; | 1072 core.int buildCounterOperationMetadataV1Beta = 0; |
1029 buildOperationMetadataV1Beta() { | 1073 buildOperationMetadataV1Beta() { |
1030 var o = new api.OperationMetadataV1Beta(); | 1074 var o = new api.OperationMetadataV1Beta(); |
1031 buildCounterOperationMetadataV1Beta++; | 1075 buildCounterOperationMetadataV1Beta++; |
1032 if (buildCounterOperationMetadataV1Beta < 3) { | 1076 if (buildCounterOperationMetadataV1Beta < 3) { |
1033 o.endTime = "foo"; | 1077 o.endTime = "foo"; |
1034 o.ephemeralMessage = "foo"; | 1078 o.ephemeralMessage = "foo"; |
1035 o.insertTime = "foo"; | 1079 o.insertTime = "foo"; |
1036 o.method = "foo"; | 1080 o.method = "foo"; |
1037 o.target = "foo"; | 1081 o.target = "foo"; |
1038 o.user = "foo"; | 1082 o.user = "foo"; |
1039 o.warning = buildUnnamed3881(); | 1083 o.warning = buildUnnamed3356(); |
1040 } | 1084 } |
1041 buildCounterOperationMetadataV1Beta--; | 1085 buildCounterOperationMetadataV1Beta--; |
1042 return o; | 1086 return o; |
1043 } | 1087 } |
1044 | 1088 |
1045 checkOperationMetadataV1Beta(api.OperationMetadataV1Beta o) { | 1089 checkOperationMetadataV1Beta(api.OperationMetadataV1Beta o) { |
1046 buildCounterOperationMetadataV1Beta++; | 1090 buildCounterOperationMetadataV1Beta++; |
1047 if (buildCounterOperationMetadataV1Beta < 3) { | 1091 if (buildCounterOperationMetadataV1Beta < 3) { |
1048 unittest.expect(o.endTime, unittest.equals('foo')); | 1092 unittest.expect(o.endTime, unittest.equals('foo')); |
1049 unittest.expect(o.ephemeralMessage, unittest.equals('foo')); | 1093 unittest.expect(o.ephemeralMessage, unittest.equals('foo')); |
1050 unittest.expect(o.insertTime, unittest.equals('foo')); | 1094 unittest.expect(o.insertTime, unittest.equals('foo')); |
1051 unittest.expect(o.method, unittest.equals('foo')); | 1095 unittest.expect(o.method, unittest.equals('foo')); |
1052 unittest.expect(o.target, unittest.equals('foo')); | 1096 unittest.expect(o.target, unittest.equals('foo')); |
1053 unittest.expect(o.user, unittest.equals('foo')); | 1097 unittest.expect(o.user, unittest.equals('foo')); |
1054 checkUnnamed3881(o.warning); | 1098 checkUnnamed3356(o.warning); |
1055 } | 1099 } |
1056 buildCounterOperationMetadataV1Beta--; | 1100 buildCounterOperationMetadataV1Beta--; |
1057 } | 1101 } |
1058 | 1102 |
1059 core.int buildCounterOperationMetadataV1Beta5 = 0; | 1103 core.int buildCounterOperationMetadataV1Beta5 = 0; |
1060 buildOperationMetadataV1Beta5() { | 1104 buildOperationMetadataV1Beta5() { |
1061 var o = new api.OperationMetadataV1Beta5(); | 1105 var o = new api.OperationMetadataV1Beta5(); |
1062 buildCounterOperationMetadataV1Beta5++; | 1106 buildCounterOperationMetadataV1Beta5++; |
1063 if (buildCounterOperationMetadataV1Beta5 < 3) { | 1107 if (buildCounterOperationMetadataV1Beta5 < 3) { |
1064 o.endTime = "foo"; | 1108 o.endTime = "foo"; |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1097 | 1141 |
1098 checkRequestUtilization(api.RequestUtilization o) { | 1142 checkRequestUtilization(api.RequestUtilization o) { |
1099 buildCounterRequestUtilization++; | 1143 buildCounterRequestUtilization++; |
1100 if (buildCounterRequestUtilization < 3) { | 1144 if (buildCounterRequestUtilization < 3) { |
1101 unittest.expect(o.targetConcurrentRequests, unittest.equals(42)); | 1145 unittest.expect(o.targetConcurrentRequests, unittest.equals(42)); |
1102 unittest.expect(o.targetRequestCountPerSec, unittest.equals(42)); | 1146 unittest.expect(o.targetRequestCountPerSec, unittest.equals(42)); |
1103 } | 1147 } |
1104 buildCounterRequestUtilization--; | 1148 buildCounterRequestUtilization--; |
1105 } | 1149 } |
1106 | 1150 |
1107 buildUnnamed3882() { | 1151 buildUnnamed3357() { |
1108 var o = new core.List<api.Volume>(); | 1152 var o = new core.List<api.Volume>(); |
1109 o.add(buildVolume()); | 1153 o.add(buildVolume()); |
1110 o.add(buildVolume()); | 1154 o.add(buildVolume()); |
1111 return o; | 1155 return o; |
1112 } | 1156 } |
1113 | 1157 |
1114 checkUnnamed3882(core.List<api.Volume> o) { | 1158 checkUnnamed3357(core.List<api.Volume> o) { |
1115 unittest.expect(o, unittest.hasLength(2)); | 1159 unittest.expect(o, unittest.hasLength(2)); |
1116 checkVolume(o[0]); | 1160 checkVolume(o[0]); |
1117 checkVolume(o[1]); | 1161 checkVolume(o[1]); |
1118 } | 1162 } |
1119 | 1163 |
1120 core.int buildCounterResources = 0; | 1164 core.int buildCounterResources = 0; |
1121 buildResources() { | 1165 buildResources() { |
1122 var o = new api.Resources(); | 1166 var o = new api.Resources(); |
1123 buildCounterResources++; | 1167 buildCounterResources++; |
1124 if (buildCounterResources < 3) { | 1168 if (buildCounterResources < 3) { |
1125 o.cpu = 42.0; | 1169 o.cpu = 42.0; |
1126 o.diskGb = 42.0; | 1170 o.diskGb = 42.0; |
1127 o.memoryGb = 42.0; | 1171 o.memoryGb = 42.0; |
1128 o.volumes = buildUnnamed3882(); | 1172 o.volumes = buildUnnamed3357(); |
1129 } | 1173 } |
1130 buildCounterResources--; | 1174 buildCounterResources--; |
1131 return o; | 1175 return o; |
1132 } | 1176 } |
1133 | 1177 |
1134 checkResources(api.Resources o) { | 1178 checkResources(api.Resources o) { |
1135 buildCounterResources++; | 1179 buildCounterResources++; |
1136 if (buildCounterResources < 3) { | 1180 if (buildCounterResources < 3) { |
1137 unittest.expect(o.cpu, unittest.equals(42.0)); | 1181 unittest.expect(o.cpu, unittest.equals(42.0)); |
1138 unittest.expect(o.diskGb, unittest.equals(42.0)); | 1182 unittest.expect(o.diskGb, unittest.equals(42.0)); |
1139 unittest.expect(o.memoryGb, unittest.equals(42.0)); | 1183 unittest.expect(o.memoryGb, unittest.equals(42.0)); |
1140 checkUnnamed3882(o.volumes); | 1184 checkUnnamed3357(o.volumes); |
1141 } | 1185 } |
1142 buildCounterResources--; | 1186 buildCounterResources--; |
1143 } | 1187 } |
1144 | 1188 |
1145 core.int buildCounterScriptHandler = 0; | 1189 core.int buildCounterScriptHandler = 0; |
1146 buildScriptHandler() { | 1190 buildScriptHandler() { |
1147 var o = new api.ScriptHandler(); | 1191 var o = new api.ScriptHandler(); |
1148 buildCounterScriptHandler++; | 1192 buildCounterScriptHandler++; |
1149 if (buildCounterScriptHandler < 3) { | 1193 if (buildCounterScriptHandler < 3) { |
1150 o.scriptPath = "foo"; | 1194 o.scriptPath = "foo"; |
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1198 | 1242 |
1199 checkSourceReference(api.SourceReference o) { | 1243 checkSourceReference(api.SourceReference o) { |
1200 buildCounterSourceReference++; | 1244 buildCounterSourceReference++; |
1201 if (buildCounterSourceReference < 3) { | 1245 if (buildCounterSourceReference < 3) { |
1202 unittest.expect(o.repository, unittest.equals('foo')); | 1246 unittest.expect(o.repository, unittest.equals('foo')); |
1203 unittest.expect(o.revisionId, unittest.equals('foo')); | 1247 unittest.expect(o.revisionId, unittest.equals('foo')); |
1204 } | 1248 } |
1205 buildCounterSourceReference--; | 1249 buildCounterSourceReference--; |
1206 } | 1250 } |
1207 | 1251 |
1208 buildUnnamed3883() { | 1252 buildUnnamed3358() { |
1209 var o = new core.Map<core.String, core.String>(); | 1253 var o = new core.Map<core.String, core.String>(); |
1210 o["x"] = "foo"; | 1254 o["x"] = "foo"; |
1211 o["y"] = "foo"; | 1255 o["y"] = "foo"; |
1212 return o; | 1256 return o; |
1213 } | 1257 } |
1214 | 1258 |
1215 checkUnnamed3883(core.Map<core.String, core.String> o) { | 1259 checkUnnamed3358(core.Map<core.String, core.String> o) { |
1216 unittest.expect(o, unittest.hasLength(2)); | 1260 unittest.expect(o, unittest.hasLength(2)); |
1217 unittest.expect(o["x"], unittest.equals('foo')); | 1261 unittest.expect(o["x"], unittest.equals('foo')); |
1218 unittest.expect(o["y"], unittest.equals('foo')); | 1262 unittest.expect(o["y"], unittest.equals('foo')); |
1219 } | 1263 } |
1220 | 1264 |
1221 core.int buildCounterStaticFilesHandler = 0; | 1265 core.int buildCounterStaticFilesHandler = 0; |
1222 buildStaticFilesHandler() { | 1266 buildStaticFilesHandler() { |
1223 var o = new api.StaticFilesHandler(); | 1267 var o = new api.StaticFilesHandler(); |
1224 buildCounterStaticFilesHandler++; | 1268 buildCounterStaticFilesHandler++; |
1225 if (buildCounterStaticFilesHandler < 3) { | 1269 if (buildCounterStaticFilesHandler < 3) { |
1226 o.applicationReadable = true; | 1270 o.applicationReadable = true; |
1227 o.expiration = "foo"; | 1271 o.expiration = "foo"; |
1228 o.httpHeaders = buildUnnamed3883(); | 1272 o.httpHeaders = buildUnnamed3358(); |
1229 o.mimeType = "foo"; | 1273 o.mimeType = "foo"; |
1230 o.path = "foo"; | 1274 o.path = "foo"; |
1231 o.requireMatchingFile = true; | 1275 o.requireMatchingFile = true; |
1232 o.uploadPathRegex = "foo"; | 1276 o.uploadPathRegex = "foo"; |
1233 } | 1277 } |
1234 buildCounterStaticFilesHandler--; | 1278 buildCounterStaticFilesHandler--; |
1235 return o; | 1279 return o; |
1236 } | 1280 } |
1237 | 1281 |
1238 checkStaticFilesHandler(api.StaticFilesHandler o) { | 1282 checkStaticFilesHandler(api.StaticFilesHandler o) { |
1239 buildCounterStaticFilesHandler++; | 1283 buildCounterStaticFilesHandler++; |
1240 if (buildCounterStaticFilesHandler < 3) { | 1284 if (buildCounterStaticFilesHandler < 3) { |
1241 unittest.expect(o.applicationReadable, unittest.isTrue); | 1285 unittest.expect(o.applicationReadable, unittest.isTrue); |
1242 unittest.expect(o.expiration, unittest.equals('foo')); | 1286 unittest.expect(o.expiration, unittest.equals('foo')); |
1243 checkUnnamed3883(o.httpHeaders); | 1287 checkUnnamed3358(o.httpHeaders); |
1244 unittest.expect(o.mimeType, unittest.equals('foo')); | 1288 unittest.expect(o.mimeType, unittest.equals('foo')); |
1245 unittest.expect(o.path, unittest.equals('foo')); | 1289 unittest.expect(o.path, unittest.equals('foo')); |
1246 unittest.expect(o.requireMatchingFile, unittest.isTrue); | 1290 unittest.expect(o.requireMatchingFile, unittest.isTrue); |
1247 unittest.expect(o.uploadPathRegex, unittest.equals('foo')); | 1291 unittest.expect(o.uploadPathRegex, unittest.equals('foo')); |
1248 } | 1292 } |
1249 buildCounterStaticFilesHandler--; | 1293 buildCounterStaticFilesHandler--; |
1250 } | 1294 } |
1251 | 1295 |
1252 buildUnnamed3884() { | 1296 buildUnnamed3359() { |
1253 var o = new core.Map<core.String, core.Object>(); | 1297 var o = new core.Map<core.String, core.Object>(); |
1254 o["x"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; | 1298 o["x"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; |
1255 o["y"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; | 1299 o["y"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; |
1256 return o; | 1300 return o; |
1257 } | 1301 } |
1258 | 1302 |
1259 checkUnnamed3884(core.Map<core.String, core.Object> o) { | 1303 checkUnnamed3359(core.Map<core.String, core.Object> o) { |
1260 unittest.expect(o, unittest.hasLength(2)); | 1304 unittest.expect(o, unittest.hasLength(2)); |
1261 var casted7 = (o["x"]) as core.Map; unittest.expect(casted7, unittest.hasLengt
h(3)); unittest.expect(casted7["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted7["bool"], unittest.equals(true)); unittest.expect(casted7["string"],
unittest.equals('foo')); | 1305 var casted7 = (o["x"]) as core.Map; unittest.expect(casted7, unittest.hasLengt
h(3)); unittest.expect(casted7["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted7["bool"], unittest.equals(true)); unittest.expect(casted7["string"],
unittest.equals('foo')); |
1262 var casted8 = (o["y"]) as core.Map; unittest.expect(casted8, unittest.hasLengt
h(3)); unittest.expect(casted8["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted8["bool"], unittest.equals(true)); unittest.expect(casted8["string"],
unittest.equals('foo')); | 1306 var casted8 = (o["y"]) as core.Map; unittest.expect(casted8, unittest.hasLengt
h(3)); unittest.expect(casted8["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted8["bool"], unittest.equals(true)); unittest.expect(casted8["string"],
unittest.equals('foo')); |
1263 } | 1307 } |
1264 | 1308 |
1265 buildUnnamed3885() { | 1309 buildUnnamed3360() { |
1266 var o = new core.List<core.Map<core.String, core.Object>>(); | 1310 var o = new core.List<core.Map<core.String, core.Object>>(); |
1267 o.add(buildUnnamed3884()); | 1311 o.add(buildUnnamed3359()); |
1268 o.add(buildUnnamed3884()); | 1312 o.add(buildUnnamed3359()); |
1269 return o; | 1313 return o; |
1270 } | 1314 } |
1271 | 1315 |
1272 checkUnnamed3885(core.List<core.Map<core.String, core.Object>> o) { | 1316 checkUnnamed3360(core.List<core.Map<core.String, core.Object>> o) { |
1273 unittest.expect(o, unittest.hasLength(2)); | 1317 unittest.expect(o, unittest.hasLength(2)); |
1274 checkUnnamed3884(o[0]); | 1318 checkUnnamed3359(o[0]); |
1275 checkUnnamed3884(o[1]); | 1319 checkUnnamed3359(o[1]); |
1276 } | 1320 } |
1277 | 1321 |
1278 core.int buildCounterStatus = 0; | 1322 core.int buildCounterStatus = 0; |
1279 buildStatus() { | 1323 buildStatus() { |
1280 var o = new api.Status(); | 1324 var o = new api.Status(); |
1281 buildCounterStatus++; | 1325 buildCounterStatus++; |
1282 if (buildCounterStatus < 3) { | 1326 if (buildCounterStatus < 3) { |
1283 o.code = 42; | 1327 o.code = 42; |
1284 o.details = buildUnnamed3885(); | 1328 o.details = buildUnnamed3360(); |
1285 o.message = "foo"; | 1329 o.message = "foo"; |
1286 } | 1330 } |
1287 buildCounterStatus--; | 1331 buildCounterStatus--; |
1288 return o; | 1332 return o; |
1289 } | 1333 } |
1290 | 1334 |
1291 checkStatus(api.Status o) { | 1335 checkStatus(api.Status o) { |
1292 buildCounterStatus++; | 1336 buildCounterStatus++; |
1293 if (buildCounterStatus < 3) { | 1337 if (buildCounterStatus < 3) { |
1294 unittest.expect(o.code, unittest.equals(42)); | 1338 unittest.expect(o.code, unittest.equals(42)); |
1295 checkUnnamed3885(o.details); | 1339 checkUnnamed3360(o.details); |
1296 unittest.expect(o.message, unittest.equals('foo')); | 1340 unittest.expect(o.message, unittest.equals('foo')); |
1297 } | 1341 } |
1298 buildCounterStatus--; | 1342 buildCounterStatus--; |
1299 } | 1343 } |
1300 | 1344 |
1301 buildUnnamed3886() { | 1345 buildUnnamed3361() { |
1302 var o = new core.Map<core.String, core.double>(); | 1346 var o = new core.Map<core.String, core.double>(); |
1303 o["x"] = 42.0; | 1347 o["x"] = 42.0; |
1304 o["y"] = 42.0; | 1348 o["y"] = 42.0; |
1305 return o; | 1349 return o; |
1306 } | 1350 } |
1307 | 1351 |
1308 checkUnnamed3886(core.Map<core.String, core.double> o) { | 1352 checkUnnamed3361(core.Map<core.String, core.double> o) { |
1309 unittest.expect(o, unittest.hasLength(2)); | 1353 unittest.expect(o, unittest.hasLength(2)); |
1310 unittest.expect(o["x"], unittest.equals(42.0)); | 1354 unittest.expect(o["x"], unittest.equals(42.0)); |
1311 unittest.expect(o["y"], unittest.equals(42.0)); | 1355 unittest.expect(o["y"], unittest.equals(42.0)); |
1312 } | 1356 } |
1313 | 1357 |
1314 core.int buildCounterTrafficSplit = 0; | 1358 core.int buildCounterTrafficSplit = 0; |
1315 buildTrafficSplit() { | 1359 buildTrafficSplit() { |
1316 var o = new api.TrafficSplit(); | 1360 var o = new api.TrafficSplit(); |
1317 buildCounterTrafficSplit++; | 1361 buildCounterTrafficSplit++; |
1318 if (buildCounterTrafficSplit < 3) { | 1362 if (buildCounterTrafficSplit < 3) { |
1319 o.allocations = buildUnnamed3886(); | 1363 o.allocations = buildUnnamed3361(); |
1320 o.shardBy = "foo"; | 1364 o.shardBy = "foo"; |
1321 } | 1365 } |
1322 buildCounterTrafficSplit--; | 1366 buildCounterTrafficSplit--; |
1323 return o; | 1367 return o; |
1324 } | 1368 } |
1325 | 1369 |
1326 checkTrafficSplit(api.TrafficSplit o) { | 1370 checkTrafficSplit(api.TrafficSplit o) { |
1327 buildCounterTrafficSplit++; | 1371 buildCounterTrafficSplit++; |
1328 if (buildCounterTrafficSplit < 3) { | 1372 if (buildCounterTrafficSplit < 3) { |
1329 checkUnnamed3886(o.allocations); | 1373 checkUnnamed3361(o.allocations); |
1330 unittest.expect(o.shardBy, unittest.equals('foo')); | 1374 unittest.expect(o.shardBy, unittest.equals('foo')); |
1331 } | 1375 } |
1332 buildCounterTrafficSplit--; | 1376 buildCounterTrafficSplit--; |
1333 } | 1377 } |
1334 | 1378 |
1335 core.int buildCounterUrlDispatchRule = 0; | 1379 core.int buildCounterUrlDispatchRule = 0; |
1336 buildUrlDispatchRule() { | 1380 buildUrlDispatchRule() { |
1337 var o = new api.UrlDispatchRule(); | 1381 var o = new api.UrlDispatchRule(); |
1338 buildCounterUrlDispatchRule++; | 1382 buildCounterUrlDispatchRule++; |
1339 if (buildCounterUrlDispatchRule < 3) { | 1383 if (buildCounterUrlDispatchRule < 3) { |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1381 unittest.expect(o.login, unittest.equals('foo')); | 1425 unittest.expect(o.login, unittest.equals('foo')); |
1382 unittest.expect(o.redirectHttpResponseCode, unittest.equals('foo')); | 1426 unittest.expect(o.redirectHttpResponseCode, unittest.equals('foo')); |
1383 checkScriptHandler(o.script); | 1427 checkScriptHandler(o.script); |
1384 unittest.expect(o.securityLevel, unittest.equals('foo')); | 1428 unittest.expect(o.securityLevel, unittest.equals('foo')); |
1385 checkStaticFilesHandler(o.staticFiles); | 1429 checkStaticFilesHandler(o.staticFiles); |
1386 unittest.expect(o.urlRegex, unittest.equals('foo')); | 1430 unittest.expect(o.urlRegex, unittest.equals('foo')); |
1387 } | 1431 } |
1388 buildCounterUrlMap--; | 1432 buildCounterUrlMap--; |
1389 } | 1433 } |
1390 | 1434 |
1391 buildUnnamed3887() { | 1435 buildUnnamed3362() { |
1392 var o = new core.Map<core.String, core.String>(); | 1436 var o = new core.Map<core.String, core.String>(); |
1393 o["x"] = "foo"; | 1437 o["x"] = "foo"; |
1394 o["y"] = "foo"; | 1438 o["y"] = "foo"; |
1395 return o; | 1439 return o; |
1396 } | 1440 } |
1397 | 1441 |
1398 checkUnnamed3887(core.Map<core.String, core.String> o) { | 1442 checkUnnamed3362(core.Map<core.String, core.String> o) { |
1399 unittest.expect(o, unittest.hasLength(2)); | 1443 unittest.expect(o, unittest.hasLength(2)); |
1400 unittest.expect(o["x"], unittest.equals('foo')); | 1444 unittest.expect(o["x"], unittest.equals('foo')); |
1401 unittest.expect(o["y"], unittest.equals('foo')); | 1445 unittest.expect(o["y"], unittest.equals('foo')); |
1402 } | 1446 } |
1403 | 1447 |
1404 buildUnnamed3888() { | 1448 buildUnnamed3363() { |
1405 var o = new core.Map<core.String, core.String>(); | 1449 var o = new core.Map<core.String, core.String>(); |
1406 o["x"] = "foo"; | 1450 o["x"] = "foo"; |
1407 o["y"] = "foo"; | 1451 o["y"] = "foo"; |
1408 return o; | 1452 return o; |
1409 } | 1453 } |
1410 | 1454 |
1411 checkUnnamed3888(core.Map<core.String, core.String> o) { | 1455 checkUnnamed3363(core.Map<core.String, core.String> o) { |
1412 unittest.expect(o, unittest.hasLength(2)); | 1456 unittest.expect(o, unittest.hasLength(2)); |
1413 unittest.expect(o["x"], unittest.equals('foo')); | 1457 unittest.expect(o["x"], unittest.equals('foo')); |
1414 unittest.expect(o["y"], unittest.equals('foo')); | 1458 unittest.expect(o["y"], unittest.equals('foo')); |
1415 } | 1459 } |
1416 | 1460 |
1417 buildUnnamed3889() { | 1461 buildUnnamed3364() { |
1418 var o = new core.List<api.ErrorHandler>(); | 1462 var o = new core.List<api.ErrorHandler>(); |
1419 o.add(buildErrorHandler()); | 1463 o.add(buildErrorHandler()); |
1420 o.add(buildErrorHandler()); | 1464 o.add(buildErrorHandler()); |
1421 return o; | 1465 return o; |
1422 } | 1466 } |
1423 | 1467 |
1424 checkUnnamed3889(core.List<api.ErrorHandler> o) { | 1468 checkUnnamed3364(core.List<api.ErrorHandler> o) { |
1425 unittest.expect(o, unittest.hasLength(2)); | 1469 unittest.expect(o, unittest.hasLength(2)); |
1426 checkErrorHandler(o[0]); | 1470 checkErrorHandler(o[0]); |
1427 checkErrorHandler(o[1]); | 1471 checkErrorHandler(o[1]); |
1428 } | 1472 } |
1429 | 1473 |
1430 buildUnnamed3890() { | 1474 buildUnnamed3365() { |
1431 var o = new core.List<api.UrlMap>(); | 1475 var o = new core.List<api.UrlMap>(); |
1432 o.add(buildUrlMap()); | 1476 o.add(buildUrlMap()); |
1433 o.add(buildUrlMap()); | 1477 o.add(buildUrlMap()); |
1434 return o; | 1478 return o; |
1435 } | 1479 } |
1436 | 1480 |
1437 checkUnnamed3890(core.List<api.UrlMap> o) { | 1481 checkUnnamed3365(core.List<api.UrlMap> o) { |
1438 unittest.expect(o, unittest.hasLength(2)); | 1482 unittest.expect(o, unittest.hasLength(2)); |
1439 checkUrlMap(o[0]); | 1483 checkUrlMap(o[0]); |
1440 checkUrlMap(o[1]); | 1484 checkUrlMap(o[1]); |
1441 } | 1485 } |
1442 | 1486 |
1443 buildUnnamed3891() { | 1487 buildUnnamed3366() { |
1444 var o = new core.List<core.String>(); | 1488 var o = new core.List<core.String>(); |
1445 o.add("foo"); | 1489 o.add("foo"); |
1446 o.add("foo"); | 1490 o.add("foo"); |
1447 return o; | 1491 return o; |
1448 } | 1492 } |
1449 | 1493 |
1450 checkUnnamed3891(core.List<core.String> o) { | 1494 checkUnnamed3366(core.List<core.String> o) { |
1451 unittest.expect(o, unittest.hasLength(2)); | 1495 unittest.expect(o, unittest.hasLength(2)); |
1452 unittest.expect(o[0], unittest.equals('foo')); | 1496 unittest.expect(o[0], unittest.equals('foo')); |
1453 unittest.expect(o[1], unittest.equals('foo')); | 1497 unittest.expect(o[1], unittest.equals('foo')); |
1454 } | 1498 } |
1455 | 1499 |
1456 buildUnnamed3892() { | 1500 buildUnnamed3367() { |
1457 var o = new core.List<api.Library>(); | 1501 var o = new core.List<api.Library>(); |
1458 o.add(buildLibrary()); | 1502 o.add(buildLibrary()); |
1459 o.add(buildLibrary()); | 1503 o.add(buildLibrary()); |
1460 return o; | 1504 return o; |
1461 } | 1505 } |
1462 | 1506 |
1463 checkUnnamed3892(core.List<api.Library> o) { | 1507 checkUnnamed3367(core.List<api.Library> o) { |
1464 unittest.expect(o, unittest.hasLength(2)); | 1508 unittest.expect(o, unittest.hasLength(2)); |
1465 checkLibrary(o[0]); | 1509 checkLibrary(o[0]); |
1466 checkLibrary(o[1]); | 1510 checkLibrary(o[1]); |
1467 } | 1511 } |
1468 | 1512 |
1469 core.int buildCounterVersion = 0; | 1513 core.int buildCounterVersion = 0; |
1470 buildVersion() { | 1514 buildVersion() { |
1471 var o = new api.Version(); | 1515 var o = new api.Version(); |
1472 buildCounterVersion++; | 1516 buildCounterVersion++; |
1473 if (buildCounterVersion < 3) { | 1517 if (buildCounterVersion < 3) { |
1474 o.apiConfig = buildApiConfigHandler(); | 1518 o.apiConfig = buildApiConfigHandler(); |
1475 o.automaticScaling = buildAutomaticScaling(); | 1519 o.automaticScaling = buildAutomaticScaling(); |
1476 o.basicScaling = buildBasicScaling(); | 1520 o.basicScaling = buildBasicScaling(); |
1477 o.betaSettings = buildUnnamed3887(); | 1521 o.betaSettings = buildUnnamed3362(); |
1478 o.creationTime = "foo"; | 1522 o.creationTime = "foo"; |
1479 o.defaultExpiration = "foo"; | 1523 o.defaultExpiration = "foo"; |
1480 o.deployer = "foo"; | 1524 o.deployer = "foo"; |
1481 o.deployment = buildDeployment(); | 1525 o.deployment = buildDeployment(); |
1482 o.diskUsageBytes = "foo"; | 1526 o.diskUsageBytes = "foo"; |
1483 o.endpointsApiService = buildEndpointsApiService(); | 1527 o.endpointsApiService = buildEndpointsApiService(); |
1484 o.env = "foo"; | 1528 o.env = "foo"; |
1485 o.envVariables = buildUnnamed3888(); | 1529 o.envVariables = buildUnnamed3363(); |
1486 o.errorHandlers = buildUnnamed3889(); | 1530 o.errorHandlers = buildUnnamed3364(); |
1487 o.handlers = buildUnnamed3890(); | 1531 o.handlers = buildUnnamed3365(); |
1488 o.healthCheck = buildHealthCheck(); | 1532 o.healthCheck = buildHealthCheck(); |
1489 o.id = "foo"; | 1533 o.id = "foo"; |
1490 o.inboundServices = buildUnnamed3891(); | 1534 o.inboundServices = buildUnnamed3366(); |
1491 o.instanceClass = "foo"; | 1535 o.instanceClass = "foo"; |
1492 o.libraries = buildUnnamed3892(); | 1536 o.libraries = buildUnnamed3367(); |
1493 o.manualScaling = buildManualScaling(); | 1537 o.manualScaling = buildManualScaling(); |
1494 o.name = "foo"; | 1538 o.name = "foo"; |
1495 o.network = buildNetwork(); | 1539 o.network = buildNetwork(); |
1496 o.nobuildFilesRegex = "foo"; | 1540 o.nobuildFilesRegex = "foo"; |
1497 o.resources = buildResources(); | 1541 o.resources = buildResources(); |
1498 o.runtime = "foo"; | 1542 o.runtime = "foo"; |
| 1543 o.runtimeApiVersion = "foo"; |
1499 o.servingStatus = "foo"; | 1544 o.servingStatus = "foo"; |
1500 o.threadsafe = true; | 1545 o.threadsafe = true; |
1501 o.vm = true; | 1546 o.vm = true; |
1502 } | 1547 } |
1503 buildCounterVersion--; | 1548 buildCounterVersion--; |
1504 return o; | 1549 return o; |
1505 } | 1550 } |
1506 | 1551 |
1507 checkVersion(api.Version o) { | 1552 checkVersion(api.Version o) { |
1508 buildCounterVersion++; | 1553 buildCounterVersion++; |
1509 if (buildCounterVersion < 3) { | 1554 if (buildCounterVersion < 3) { |
1510 checkApiConfigHandler(o.apiConfig); | 1555 checkApiConfigHandler(o.apiConfig); |
1511 checkAutomaticScaling(o.automaticScaling); | 1556 checkAutomaticScaling(o.automaticScaling); |
1512 checkBasicScaling(o.basicScaling); | 1557 checkBasicScaling(o.basicScaling); |
1513 checkUnnamed3887(o.betaSettings); | 1558 checkUnnamed3362(o.betaSettings); |
1514 unittest.expect(o.creationTime, unittest.equals('foo')); | 1559 unittest.expect(o.creationTime, unittest.equals('foo')); |
1515 unittest.expect(o.defaultExpiration, unittest.equals('foo')); | 1560 unittest.expect(o.defaultExpiration, unittest.equals('foo')); |
1516 unittest.expect(o.deployer, unittest.equals('foo')); | 1561 unittest.expect(o.deployer, unittest.equals('foo')); |
1517 checkDeployment(o.deployment); | 1562 checkDeployment(o.deployment); |
1518 unittest.expect(o.diskUsageBytes, unittest.equals('foo')); | 1563 unittest.expect(o.diskUsageBytes, unittest.equals('foo')); |
1519 checkEndpointsApiService(o.endpointsApiService); | 1564 checkEndpointsApiService(o.endpointsApiService); |
1520 unittest.expect(o.env, unittest.equals('foo')); | 1565 unittest.expect(o.env, unittest.equals('foo')); |
1521 checkUnnamed3888(o.envVariables); | 1566 checkUnnamed3363(o.envVariables); |
1522 checkUnnamed3889(o.errorHandlers); | 1567 checkUnnamed3364(o.errorHandlers); |
1523 checkUnnamed3890(o.handlers); | 1568 checkUnnamed3365(o.handlers); |
1524 checkHealthCheck(o.healthCheck); | 1569 checkHealthCheck(o.healthCheck); |
1525 unittest.expect(o.id, unittest.equals('foo')); | 1570 unittest.expect(o.id, unittest.equals('foo')); |
1526 checkUnnamed3891(o.inboundServices); | 1571 checkUnnamed3366(o.inboundServices); |
1527 unittest.expect(o.instanceClass, unittest.equals('foo')); | 1572 unittest.expect(o.instanceClass, unittest.equals('foo')); |
1528 checkUnnamed3892(o.libraries); | 1573 checkUnnamed3367(o.libraries); |
1529 checkManualScaling(o.manualScaling); | 1574 checkManualScaling(o.manualScaling); |
1530 unittest.expect(o.name, unittest.equals('foo')); | 1575 unittest.expect(o.name, unittest.equals('foo')); |
1531 checkNetwork(o.network); | 1576 checkNetwork(o.network); |
1532 unittest.expect(o.nobuildFilesRegex, unittest.equals('foo')); | 1577 unittest.expect(o.nobuildFilesRegex, unittest.equals('foo')); |
1533 checkResources(o.resources); | 1578 checkResources(o.resources); |
1534 unittest.expect(o.runtime, unittest.equals('foo')); | 1579 unittest.expect(o.runtime, unittest.equals('foo')); |
| 1580 unittest.expect(o.runtimeApiVersion, unittest.equals('foo')); |
1535 unittest.expect(o.servingStatus, unittest.equals('foo')); | 1581 unittest.expect(o.servingStatus, unittest.equals('foo')); |
1536 unittest.expect(o.threadsafe, unittest.isTrue); | 1582 unittest.expect(o.threadsafe, unittest.isTrue); |
1537 unittest.expect(o.vm, unittest.isTrue); | 1583 unittest.expect(o.vm, unittest.isTrue); |
1538 } | 1584 } |
1539 buildCounterVersion--; | 1585 buildCounterVersion--; |
1540 } | 1586 } |
1541 | 1587 |
1542 core.int buildCounterVolume = 0; | 1588 core.int buildCounterVolume = 0; |
1543 buildVolume() { | 1589 buildVolume() { |
1544 var o = new api.Volume(); | 1590 var o = new api.Volume(); |
(...skipping 291 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1836 | 1882 |
1837 unittest.group("obj-schema-OperationMetadataV1", () { | 1883 unittest.group("obj-schema-OperationMetadataV1", () { |
1838 unittest.test("to-json--from-json", () { | 1884 unittest.test("to-json--from-json", () { |
1839 var o = buildOperationMetadataV1(); | 1885 var o = buildOperationMetadataV1(); |
1840 var od = new api.OperationMetadataV1.fromJson(o.toJson()); | 1886 var od = new api.OperationMetadataV1.fromJson(o.toJson()); |
1841 checkOperationMetadataV1(od); | 1887 checkOperationMetadataV1(od); |
1842 }); | 1888 }); |
1843 }); | 1889 }); |
1844 | 1890 |
1845 | 1891 |
| 1892 unittest.group("obj-schema-OperationMetadataV1Alpha", () { |
| 1893 unittest.test("to-json--from-json", () { |
| 1894 var o = buildOperationMetadataV1Alpha(); |
| 1895 var od = new api.OperationMetadataV1Alpha.fromJson(o.toJson()); |
| 1896 checkOperationMetadataV1Alpha(od); |
| 1897 }); |
| 1898 }); |
| 1899 |
| 1900 |
1846 unittest.group("obj-schema-OperationMetadataV1Beta", () { | 1901 unittest.group("obj-schema-OperationMetadataV1Beta", () { |
1847 unittest.test("to-json--from-json", () { | 1902 unittest.test("to-json--from-json", () { |
1848 var o = buildOperationMetadataV1Beta(); | 1903 var o = buildOperationMetadataV1Beta(); |
1849 var od = new api.OperationMetadataV1Beta.fromJson(o.toJson()); | 1904 var od = new api.OperationMetadataV1Beta.fromJson(o.toJson()); |
1850 checkOperationMetadataV1Beta(od); | 1905 checkOperationMetadataV1Beta(od); |
1851 }); | 1906 }); |
1852 }); | 1907 }); |
1853 | 1908 |
1854 | 1909 |
1855 unittest.group("obj-schema-OperationMetadataV1Beta5", () { | 1910 unittest.group("obj-schema-OperationMetadataV1Beta5", () { |
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1968 }); | 2023 }); |
1969 }); | 2024 }); |
1970 | 2025 |
1971 | 2026 |
1972 unittest.group("resource-AppsResourceApi", () { | 2027 unittest.group("resource-AppsResourceApi", () { |
1973 unittest.test("method--create", () { | 2028 unittest.test("method--create", () { |
1974 | 2029 |
1975 var mock = new HttpServerMock(); | 2030 var mock = new HttpServerMock(); |
1976 api.AppsResourceApi res = new api.AppengineApi(mock).apps; | 2031 api.AppsResourceApi res = new api.AppengineApi(mock).apps; |
1977 var arg_request = buildApplication(); | 2032 var arg_request = buildApplication(); |
1978 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2033 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
1979 var obj = new api.Application.fromJson(json); | 2034 var obj = new api.Application.fromJson(json); |
1980 checkApplication(obj); | 2035 checkApplication(obj); |
1981 | 2036 |
1982 var path = (req.url).path; | 2037 var path = (req.url).path; |
1983 var pathOffset = 0; | 2038 var pathOffset = 0; |
1984 var index; | 2039 var index; |
1985 var subPart; | 2040 var subPart; |
1986 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2041 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
1987 pathOffset += 1; | 2042 pathOffset += 1; |
1988 unittest.expect(path.substring(pathOffset, pathOffset + 12), unittest.eq
uals("v1beta5/apps")); | 2043 unittest.expect(path.substring(pathOffset, pathOffset + 12), unittest.eq
uals("v1beta5/apps")); |
(...skipping 16 matching lines...) Expand all Loading... |
2005 } | 2060 } |
2006 } | 2061 } |
2007 | 2062 |
2008 | 2063 |
2009 var h = { | 2064 var h = { |
2010 "content-type" : "application/json; charset=utf-8", | 2065 "content-type" : "application/json; charset=utf-8", |
2011 }; | 2066 }; |
2012 var resp = convert.JSON.encode(buildOperation()); | 2067 var resp = convert.JSON.encode(buildOperation()); |
2013 return new async.Future.value(stringResponse(200, h, resp)); | 2068 return new async.Future.value(stringResponse(200, h, resp)); |
2014 }), true); | 2069 }), true); |
2015 res.create(arg_request).then(unittest.expectAsync(((api.Operation response
) { | 2070 res.create(arg_request).then(unittest.expectAsync1(((api.Operation respons
e) { |
2016 checkOperation(response); | 2071 checkOperation(response); |
2017 }))); | 2072 }))); |
2018 }); | 2073 }); |
2019 | 2074 |
2020 unittest.test("method--get", () { | 2075 unittest.test("method--get", () { |
2021 | 2076 |
2022 var mock = new HttpServerMock(); | 2077 var mock = new HttpServerMock(); |
2023 api.AppsResourceApi res = new api.AppengineApi(mock).apps; | 2078 api.AppsResourceApi res = new api.AppengineApi(mock).apps; |
2024 var arg_appsId = "foo"; | 2079 var arg_appsId = "foo"; |
2025 var arg_ensureResourcesExist = true; | 2080 var arg_ensureResourcesExist = true; |
2026 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2081 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2027 var path = (req.url).path; | 2082 var path = (req.url).path; |
2028 var pathOffset = 0; | 2083 var pathOffset = 0; |
2029 var index; | 2084 var index; |
2030 var subPart; | 2085 var subPart; |
2031 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2086 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2032 pathOffset += 1; | 2087 pathOffset += 1; |
2033 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); | 2088 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); |
2034 pathOffset += 13; | 2089 pathOffset += 13; |
2035 subPart = core.Uri.decodeQueryComponent(path.substring(pathOffset)); | 2090 subPart = core.Uri.decodeQueryComponent(path.substring(pathOffset)); |
2036 pathOffset = path.length; | 2091 pathOffset = path.length; |
(...skipping 17 matching lines...) Expand all Loading... |
2054 } | 2109 } |
2055 unittest.expect(queryMap["ensureResourcesExist"].first, unittest.equals(
"$arg_ensureResourcesExist")); | 2110 unittest.expect(queryMap["ensureResourcesExist"].first, unittest.equals(
"$arg_ensureResourcesExist")); |
2056 | 2111 |
2057 | 2112 |
2058 var h = { | 2113 var h = { |
2059 "content-type" : "application/json; charset=utf-8", | 2114 "content-type" : "application/json; charset=utf-8", |
2060 }; | 2115 }; |
2061 var resp = convert.JSON.encode(buildApplication()); | 2116 var resp = convert.JSON.encode(buildApplication()); |
2062 return new async.Future.value(stringResponse(200, h, resp)); | 2117 return new async.Future.value(stringResponse(200, h, resp)); |
2063 }), true); | 2118 }), true); |
2064 res.get(arg_appsId, ensureResourcesExist: arg_ensureResourcesExist).then(u
nittest.expectAsync(((api.Application response) { | 2119 res.get(arg_appsId, ensureResourcesExist: arg_ensureResourcesExist).then(u
nittest.expectAsync1(((api.Application response) { |
2065 checkApplication(response); | 2120 checkApplication(response); |
2066 }))); | 2121 }))); |
2067 }); | 2122 }); |
2068 | 2123 |
2069 unittest.test("method--patch", () { | 2124 unittest.test("method--patch", () { |
2070 | 2125 |
2071 var mock = new HttpServerMock(); | 2126 var mock = new HttpServerMock(); |
2072 api.AppsResourceApi res = new api.AppengineApi(mock).apps; | 2127 api.AppsResourceApi res = new api.AppengineApi(mock).apps; |
2073 var arg_request = buildApplication(); | 2128 var arg_request = buildApplication(); |
2074 var arg_appsId = "foo"; | 2129 var arg_appsId = "foo"; |
2075 var arg_mask = "foo"; | 2130 var arg_mask = "foo"; |
2076 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2131 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2077 var obj = new api.Application.fromJson(json); | 2132 var obj = new api.Application.fromJson(json); |
2078 checkApplication(obj); | 2133 checkApplication(obj); |
2079 | 2134 |
2080 var path = (req.url).path; | 2135 var path = (req.url).path; |
2081 var pathOffset = 0; | 2136 var pathOffset = 0; |
2082 var index; | 2137 var index; |
2083 var subPart; | 2138 var subPart; |
2084 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2139 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2085 pathOffset += 1; | 2140 pathOffset += 1; |
2086 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); | 2141 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); |
(...skipping 20 matching lines...) Expand all Loading... |
2107 } | 2162 } |
2108 unittest.expect(queryMap["mask"].first, unittest.equals(arg_mask)); | 2163 unittest.expect(queryMap["mask"].first, unittest.equals(arg_mask)); |
2109 | 2164 |
2110 | 2165 |
2111 var h = { | 2166 var h = { |
2112 "content-type" : "application/json; charset=utf-8", | 2167 "content-type" : "application/json; charset=utf-8", |
2113 }; | 2168 }; |
2114 var resp = convert.JSON.encode(buildOperation()); | 2169 var resp = convert.JSON.encode(buildOperation()); |
2115 return new async.Future.value(stringResponse(200, h, resp)); | 2170 return new async.Future.value(stringResponse(200, h, resp)); |
2116 }), true); | 2171 }), true); |
2117 res.patch(arg_request, arg_appsId, mask: arg_mask).then(unittest.expectAsy
nc(((api.Operation response) { | 2172 res.patch(arg_request, arg_appsId, mask: arg_mask).then(unittest.expectAsy
nc1(((api.Operation response) { |
2118 checkOperation(response); | 2173 checkOperation(response); |
2119 }))); | 2174 }))); |
2120 }); | 2175 }); |
2121 | 2176 |
2122 }); | 2177 }); |
2123 | 2178 |
2124 | 2179 |
2125 unittest.group("resource-AppsLocationsResourceApi", () { | 2180 unittest.group("resource-AppsLocationsResourceApi", () { |
2126 unittest.test("method--get", () { | 2181 unittest.test("method--get", () { |
2127 | 2182 |
2128 var mock = new HttpServerMock(); | 2183 var mock = new HttpServerMock(); |
2129 api.AppsLocationsResourceApi res = new api.AppengineApi(mock).apps.locatio
ns; | 2184 api.AppsLocationsResourceApi res = new api.AppengineApi(mock).apps.locatio
ns; |
2130 var arg_appsId = "foo"; | 2185 var arg_appsId = "foo"; |
2131 var arg_locationsId = "foo"; | 2186 var arg_locationsId = "foo"; |
2132 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2187 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2133 var path = (req.url).path; | 2188 var path = (req.url).path; |
2134 var pathOffset = 0; | 2189 var pathOffset = 0; |
2135 var index; | 2190 var index; |
2136 var subPart; | 2191 var subPart; |
2137 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2192 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2138 pathOffset += 1; | 2193 pathOffset += 1; |
2139 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); | 2194 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); |
2140 pathOffset += 13; | 2195 pathOffset += 13; |
2141 index = path.indexOf("/locations/", pathOffset); | 2196 index = path.indexOf("/locations/", pathOffset); |
2142 unittest.expect(index >= 0, unittest.isTrue); | 2197 unittest.expect(index >= 0, unittest.isTrue); |
(...skipping 23 matching lines...) Expand all Loading... |
2166 } | 2221 } |
2167 } | 2222 } |
2168 | 2223 |
2169 | 2224 |
2170 var h = { | 2225 var h = { |
2171 "content-type" : "application/json; charset=utf-8", | 2226 "content-type" : "application/json; charset=utf-8", |
2172 }; | 2227 }; |
2173 var resp = convert.JSON.encode(buildLocation()); | 2228 var resp = convert.JSON.encode(buildLocation()); |
2174 return new async.Future.value(stringResponse(200, h, resp)); | 2229 return new async.Future.value(stringResponse(200, h, resp)); |
2175 }), true); | 2230 }), true); |
2176 res.get(arg_appsId, arg_locationsId).then(unittest.expectAsync(((api.Locat
ion response) { | 2231 res.get(arg_appsId, arg_locationsId).then(unittest.expectAsync1(((api.Loca
tion response) { |
2177 checkLocation(response); | 2232 checkLocation(response); |
2178 }))); | 2233 }))); |
2179 }); | 2234 }); |
2180 | 2235 |
2181 unittest.test("method--list", () { | 2236 unittest.test("method--list", () { |
2182 | 2237 |
2183 var mock = new HttpServerMock(); | 2238 var mock = new HttpServerMock(); |
2184 api.AppsLocationsResourceApi res = new api.AppengineApi(mock).apps.locatio
ns; | 2239 api.AppsLocationsResourceApi res = new api.AppengineApi(mock).apps.locatio
ns; |
2185 var arg_appsId = "foo"; | 2240 var arg_appsId = "foo"; |
2186 var arg_filter = "foo"; | |
2187 var arg_pageToken = "foo"; | 2241 var arg_pageToken = "foo"; |
2188 var arg_pageSize = 42; | 2242 var arg_pageSize = 42; |
2189 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2243 var arg_filter = "foo"; |
| 2244 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2190 var path = (req.url).path; | 2245 var path = (req.url).path; |
2191 var pathOffset = 0; | 2246 var pathOffset = 0; |
2192 var index; | 2247 var index; |
2193 var subPart; | 2248 var subPart; |
2194 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2249 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2195 pathOffset += 1; | 2250 pathOffset += 1; |
2196 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); | 2251 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); |
2197 pathOffset += 13; | 2252 pathOffset += 13; |
2198 index = path.indexOf("/locations", pathOffset); | 2253 index = path.indexOf("/locations", pathOffset); |
2199 unittest.expect(index >= 0, unittest.isTrue); | 2254 unittest.expect(index >= 0, unittest.isTrue); |
(...skipping 12 matching lines...) Expand all Loading... |
2212 if (n == "false") return false; | 2267 if (n == "false") return false; |
2213 if (n == null) return null; | 2268 if (n == null) return null; |
2214 throw new core.ArgumentError("Invalid boolean: $n"); | 2269 throw new core.ArgumentError("Invalid boolean: $n"); |
2215 } | 2270 } |
2216 if (query.length > 0) { | 2271 if (query.length > 0) { |
2217 for (var part in query.split("&")) { | 2272 for (var part in query.split("&")) { |
2218 var keyvalue = part.split("="); | 2273 var keyvalue = part.split("="); |
2219 addQueryParam(core.Uri.decodeQueryComponent(keyvalue[0]), core.Uri.d
ecodeQueryComponent(keyvalue[1])); | 2274 addQueryParam(core.Uri.decodeQueryComponent(keyvalue[0]), core.Uri.d
ecodeQueryComponent(keyvalue[1])); |
2220 } | 2275 } |
2221 } | 2276 } |
2222 unittest.expect(queryMap["filter"].first, unittest.equals(arg_filter)); | |
2223 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); | 2277 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); |
2224 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); | 2278 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); |
| 2279 unittest.expect(queryMap["filter"].first, unittest.equals(arg_filter)); |
2225 | 2280 |
2226 | 2281 |
2227 var h = { | 2282 var h = { |
2228 "content-type" : "application/json; charset=utf-8", | 2283 "content-type" : "application/json; charset=utf-8", |
2229 }; | 2284 }; |
2230 var resp = convert.JSON.encode(buildListLocationsResponse()); | 2285 var resp = convert.JSON.encode(buildListLocationsResponse()); |
2231 return new async.Future.value(stringResponse(200, h, resp)); | 2286 return new async.Future.value(stringResponse(200, h, resp)); |
2232 }), true); | 2287 }), true); |
2233 res.list(arg_appsId, filter: arg_filter, pageToken: arg_pageToken, pageSiz
e: arg_pageSize).then(unittest.expectAsync(((api.ListLocationsResponse response)
{ | 2288 res.list(arg_appsId, pageToken: arg_pageToken, pageSize: arg_pageSize, fil
ter: arg_filter).then(unittest.expectAsync1(((api.ListLocationsResponse response
) { |
2234 checkListLocationsResponse(response); | 2289 checkListLocationsResponse(response); |
2235 }))); | 2290 }))); |
2236 }); | 2291 }); |
2237 | 2292 |
2238 }); | 2293 }); |
2239 | 2294 |
2240 | 2295 |
2241 unittest.group("resource-AppsOperationsResourceApi", () { | 2296 unittest.group("resource-AppsOperationsResourceApi", () { |
2242 unittest.test("method--get", () { | 2297 unittest.test("method--get", () { |
2243 | 2298 |
2244 var mock = new HttpServerMock(); | 2299 var mock = new HttpServerMock(); |
2245 api.AppsOperationsResourceApi res = new api.AppengineApi(mock).apps.operat
ions; | 2300 api.AppsOperationsResourceApi res = new api.AppengineApi(mock).apps.operat
ions; |
2246 var arg_appsId = "foo"; | 2301 var arg_appsId = "foo"; |
2247 var arg_operationsId = "foo"; | 2302 var arg_operationsId = "foo"; |
2248 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2303 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2249 var path = (req.url).path; | 2304 var path = (req.url).path; |
2250 var pathOffset = 0; | 2305 var pathOffset = 0; |
2251 var index; | 2306 var index; |
2252 var subPart; | 2307 var subPart; |
2253 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2308 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2254 pathOffset += 1; | 2309 pathOffset += 1; |
2255 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); | 2310 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); |
2256 pathOffset += 13; | 2311 pathOffset += 13; |
2257 index = path.indexOf("/operations/", pathOffset); | 2312 index = path.indexOf("/operations/", pathOffset); |
2258 unittest.expect(index >= 0, unittest.isTrue); | 2313 unittest.expect(index >= 0, unittest.isTrue); |
(...skipping 23 matching lines...) Expand all Loading... |
2282 } | 2337 } |
2283 } | 2338 } |
2284 | 2339 |
2285 | 2340 |
2286 var h = { | 2341 var h = { |
2287 "content-type" : "application/json; charset=utf-8", | 2342 "content-type" : "application/json; charset=utf-8", |
2288 }; | 2343 }; |
2289 var resp = convert.JSON.encode(buildOperation()); | 2344 var resp = convert.JSON.encode(buildOperation()); |
2290 return new async.Future.value(stringResponse(200, h, resp)); | 2345 return new async.Future.value(stringResponse(200, h, resp)); |
2291 }), true); | 2346 }), true); |
2292 res.get(arg_appsId, arg_operationsId).then(unittest.expectAsync(((api.Oper
ation response) { | 2347 res.get(arg_appsId, arg_operationsId).then(unittest.expectAsync1(((api.Ope
ration response) { |
2293 checkOperation(response); | 2348 checkOperation(response); |
2294 }))); | 2349 }))); |
2295 }); | 2350 }); |
2296 | 2351 |
2297 unittest.test("method--list", () { | 2352 unittest.test("method--list", () { |
2298 | 2353 |
2299 var mock = new HttpServerMock(); | 2354 var mock = new HttpServerMock(); |
2300 api.AppsOperationsResourceApi res = new api.AppengineApi(mock).apps.operat
ions; | 2355 api.AppsOperationsResourceApi res = new api.AppengineApi(mock).apps.operat
ions; |
2301 var arg_appsId = "foo"; | 2356 var arg_appsId = "foo"; |
2302 var arg_filter = "foo"; | |
2303 var arg_pageToken = "foo"; | 2357 var arg_pageToken = "foo"; |
2304 var arg_pageSize = 42; | 2358 var arg_pageSize = 42; |
2305 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2359 var arg_filter = "foo"; |
| 2360 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2306 var path = (req.url).path; | 2361 var path = (req.url).path; |
2307 var pathOffset = 0; | 2362 var pathOffset = 0; |
2308 var index; | 2363 var index; |
2309 var subPart; | 2364 var subPart; |
2310 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2365 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2311 pathOffset += 1; | 2366 pathOffset += 1; |
2312 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); | 2367 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); |
2313 pathOffset += 13; | 2368 pathOffset += 13; |
2314 index = path.indexOf("/operations", pathOffset); | 2369 index = path.indexOf("/operations", pathOffset); |
2315 unittest.expect(index >= 0, unittest.isTrue); | 2370 unittest.expect(index >= 0, unittest.isTrue); |
(...skipping 12 matching lines...) Expand all Loading... |
2328 if (n == "false") return false; | 2383 if (n == "false") return false; |
2329 if (n == null) return null; | 2384 if (n == null) return null; |
2330 throw new core.ArgumentError("Invalid boolean: $n"); | 2385 throw new core.ArgumentError("Invalid boolean: $n"); |
2331 } | 2386 } |
2332 if (query.length > 0) { | 2387 if (query.length > 0) { |
2333 for (var part in query.split("&")) { | 2388 for (var part in query.split("&")) { |
2334 var keyvalue = part.split("="); | 2389 var keyvalue = part.split("="); |
2335 addQueryParam(core.Uri.decodeQueryComponent(keyvalue[0]), core.Uri.d
ecodeQueryComponent(keyvalue[1])); | 2390 addQueryParam(core.Uri.decodeQueryComponent(keyvalue[0]), core.Uri.d
ecodeQueryComponent(keyvalue[1])); |
2336 } | 2391 } |
2337 } | 2392 } |
2338 unittest.expect(queryMap["filter"].first, unittest.equals(arg_filter)); | |
2339 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); | 2393 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); |
2340 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); | 2394 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); |
| 2395 unittest.expect(queryMap["filter"].first, unittest.equals(arg_filter)); |
2341 | 2396 |
2342 | 2397 |
2343 var h = { | 2398 var h = { |
2344 "content-type" : "application/json; charset=utf-8", | 2399 "content-type" : "application/json; charset=utf-8", |
2345 }; | 2400 }; |
2346 var resp = convert.JSON.encode(buildListOperationsResponse()); | 2401 var resp = convert.JSON.encode(buildListOperationsResponse()); |
2347 return new async.Future.value(stringResponse(200, h, resp)); | 2402 return new async.Future.value(stringResponse(200, h, resp)); |
2348 }), true); | 2403 }), true); |
2349 res.list(arg_appsId, filter: arg_filter, pageToken: arg_pageToken, pageSiz
e: arg_pageSize).then(unittest.expectAsync(((api.ListOperationsResponse response
) { | 2404 res.list(arg_appsId, pageToken: arg_pageToken, pageSize: arg_pageSize, fil
ter: arg_filter).then(unittest.expectAsync1(((api.ListOperationsResponse respons
e) { |
2350 checkListOperationsResponse(response); | 2405 checkListOperationsResponse(response); |
2351 }))); | 2406 }))); |
2352 }); | 2407 }); |
2353 | 2408 |
2354 }); | 2409 }); |
2355 | 2410 |
2356 | 2411 |
2357 unittest.group("resource-AppsServicesResourceApi", () { | 2412 unittest.group("resource-AppsServicesResourceApi", () { |
2358 unittest.test("method--delete", () { | 2413 unittest.test("method--delete", () { |
2359 | 2414 |
2360 var mock = new HttpServerMock(); | 2415 var mock = new HttpServerMock(); |
2361 api.AppsServicesResourceApi res = new api.AppengineApi(mock).apps.services
; | 2416 api.AppsServicesResourceApi res = new api.AppengineApi(mock).apps.services
; |
2362 var arg_appsId = "foo"; | 2417 var arg_appsId = "foo"; |
2363 var arg_servicesId = "foo"; | 2418 var arg_servicesId = "foo"; |
2364 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2419 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2365 var path = (req.url).path; | 2420 var path = (req.url).path; |
2366 var pathOffset = 0; | 2421 var pathOffset = 0; |
2367 var index; | 2422 var index; |
2368 var subPart; | 2423 var subPart; |
2369 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2424 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2370 pathOffset += 1; | 2425 pathOffset += 1; |
2371 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); | 2426 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); |
2372 pathOffset += 13; | 2427 pathOffset += 13; |
2373 index = path.indexOf("/services/", pathOffset); | 2428 index = path.indexOf("/services/", pathOffset); |
2374 unittest.expect(index >= 0, unittest.isTrue); | 2429 unittest.expect(index >= 0, unittest.isTrue); |
(...skipping 23 matching lines...) Expand all Loading... |
2398 } | 2453 } |
2399 } | 2454 } |
2400 | 2455 |
2401 | 2456 |
2402 var h = { | 2457 var h = { |
2403 "content-type" : "application/json; charset=utf-8", | 2458 "content-type" : "application/json; charset=utf-8", |
2404 }; | 2459 }; |
2405 var resp = convert.JSON.encode(buildOperation()); | 2460 var resp = convert.JSON.encode(buildOperation()); |
2406 return new async.Future.value(stringResponse(200, h, resp)); | 2461 return new async.Future.value(stringResponse(200, h, resp)); |
2407 }), true); | 2462 }), true); |
2408 res.delete(arg_appsId, arg_servicesId).then(unittest.expectAsync(((api.Ope
ration response) { | 2463 res.delete(arg_appsId, arg_servicesId).then(unittest.expectAsync1(((api.Op
eration response) { |
2409 checkOperation(response); | 2464 checkOperation(response); |
2410 }))); | 2465 }))); |
2411 }); | 2466 }); |
2412 | 2467 |
2413 unittest.test("method--get", () { | 2468 unittest.test("method--get", () { |
2414 | 2469 |
2415 var mock = new HttpServerMock(); | 2470 var mock = new HttpServerMock(); |
2416 api.AppsServicesResourceApi res = new api.AppengineApi(mock).apps.services
; | 2471 api.AppsServicesResourceApi res = new api.AppengineApi(mock).apps.services
; |
2417 var arg_appsId = "foo"; | 2472 var arg_appsId = "foo"; |
2418 var arg_servicesId = "foo"; | 2473 var arg_servicesId = "foo"; |
2419 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2474 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2420 var path = (req.url).path; | 2475 var path = (req.url).path; |
2421 var pathOffset = 0; | 2476 var pathOffset = 0; |
2422 var index; | 2477 var index; |
2423 var subPart; | 2478 var subPart; |
2424 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2479 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2425 pathOffset += 1; | 2480 pathOffset += 1; |
2426 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); | 2481 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); |
2427 pathOffset += 13; | 2482 pathOffset += 13; |
2428 index = path.indexOf("/services/", pathOffset); | 2483 index = path.indexOf("/services/", pathOffset); |
2429 unittest.expect(index >= 0, unittest.isTrue); | 2484 unittest.expect(index >= 0, unittest.isTrue); |
(...skipping 23 matching lines...) Expand all Loading... |
2453 } | 2508 } |
2454 } | 2509 } |
2455 | 2510 |
2456 | 2511 |
2457 var h = { | 2512 var h = { |
2458 "content-type" : "application/json; charset=utf-8", | 2513 "content-type" : "application/json; charset=utf-8", |
2459 }; | 2514 }; |
2460 var resp = convert.JSON.encode(buildService()); | 2515 var resp = convert.JSON.encode(buildService()); |
2461 return new async.Future.value(stringResponse(200, h, resp)); | 2516 return new async.Future.value(stringResponse(200, h, resp)); |
2462 }), true); | 2517 }), true); |
2463 res.get(arg_appsId, arg_servicesId).then(unittest.expectAsync(((api.Servic
e response) { | 2518 res.get(arg_appsId, arg_servicesId).then(unittest.expectAsync1(((api.Servi
ce response) { |
2464 checkService(response); | 2519 checkService(response); |
2465 }))); | 2520 }))); |
2466 }); | 2521 }); |
2467 | 2522 |
2468 unittest.test("method--list", () { | 2523 unittest.test("method--list", () { |
2469 | 2524 |
2470 var mock = new HttpServerMock(); | 2525 var mock = new HttpServerMock(); |
2471 api.AppsServicesResourceApi res = new api.AppengineApi(mock).apps.services
; | 2526 api.AppsServicesResourceApi res = new api.AppengineApi(mock).apps.services
; |
2472 var arg_appsId = "foo"; | 2527 var arg_appsId = "foo"; |
2473 var arg_pageToken = "foo"; | 2528 var arg_pageToken = "foo"; |
2474 var arg_pageSize = 42; | 2529 var arg_pageSize = 42; |
2475 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2530 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2476 var path = (req.url).path; | 2531 var path = (req.url).path; |
2477 var pathOffset = 0; | 2532 var pathOffset = 0; |
2478 var index; | 2533 var index; |
2479 var subPart; | 2534 var subPart; |
2480 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2535 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2481 pathOffset += 1; | 2536 pathOffset += 1; |
2482 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); | 2537 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); |
2483 pathOffset += 13; | 2538 pathOffset += 13; |
2484 index = path.indexOf("/services", pathOffset); | 2539 index = path.indexOf("/services", pathOffset); |
2485 unittest.expect(index >= 0, unittest.isTrue); | 2540 unittest.expect(index >= 0, unittest.isTrue); |
(...skipping 22 matching lines...) Expand all Loading... |
2508 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); | 2563 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); |
2509 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); | 2564 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); |
2510 | 2565 |
2511 | 2566 |
2512 var h = { | 2567 var h = { |
2513 "content-type" : "application/json; charset=utf-8", | 2568 "content-type" : "application/json; charset=utf-8", |
2514 }; | 2569 }; |
2515 var resp = convert.JSON.encode(buildListServicesResponse()); | 2570 var resp = convert.JSON.encode(buildListServicesResponse()); |
2516 return new async.Future.value(stringResponse(200, h, resp)); | 2571 return new async.Future.value(stringResponse(200, h, resp)); |
2517 }), true); | 2572 }), true); |
2518 res.list(arg_appsId, pageToken: arg_pageToken, pageSize: arg_pageSize).the
n(unittest.expectAsync(((api.ListServicesResponse response) { | 2573 res.list(arg_appsId, pageToken: arg_pageToken, pageSize: arg_pageSize).the
n(unittest.expectAsync1(((api.ListServicesResponse response) { |
2519 checkListServicesResponse(response); | 2574 checkListServicesResponse(response); |
2520 }))); | 2575 }))); |
2521 }); | 2576 }); |
2522 | 2577 |
2523 unittest.test("method--patch", () { | 2578 unittest.test("method--patch", () { |
2524 | 2579 |
2525 var mock = new HttpServerMock(); | 2580 var mock = new HttpServerMock(); |
2526 api.AppsServicesResourceApi res = new api.AppengineApi(mock).apps.services
; | 2581 api.AppsServicesResourceApi res = new api.AppengineApi(mock).apps.services
; |
2527 var arg_request = buildService(); | 2582 var arg_request = buildService(); |
2528 var arg_appsId = "foo"; | 2583 var arg_appsId = "foo"; |
2529 var arg_servicesId = "foo"; | 2584 var arg_servicesId = "foo"; |
2530 var arg_migrateTraffic = true; | 2585 var arg_migrateTraffic = true; |
2531 var arg_mask = "foo"; | 2586 var arg_mask = "foo"; |
2532 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2587 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2533 var obj = new api.Service.fromJson(json); | 2588 var obj = new api.Service.fromJson(json); |
2534 checkService(obj); | 2589 checkService(obj); |
2535 | 2590 |
2536 var path = (req.url).path; | 2591 var path = (req.url).path; |
2537 var pathOffset = 0; | 2592 var pathOffset = 0; |
2538 var index; | 2593 var index; |
2539 var subPart; | 2594 var subPart; |
2540 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2595 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2541 pathOffset += 1; | 2596 pathOffset += 1; |
2542 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); | 2597 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); |
(...skipping 28 matching lines...) Expand all Loading... |
2571 unittest.expect(queryMap["migrateTraffic"].first, unittest.equals("$arg_
migrateTraffic")); | 2626 unittest.expect(queryMap["migrateTraffic"].first, unittest.equals("$arg_
migrateTraffic")); |
2572 unittest.expect(queryMap["mask"].first, unittest.equals(arg_mask)); | 2627 unittest.expect(queryMap["mask"].first, unittest.equals(arg_mask)); |
2573 | 2628 |
2574 | 2629 |
2575 var h = { | 2630 var h = { |
2576 "content-type" : "application/json; charset=utf-8", | 2631 "content-type" : "application/json; charset=utf-8", |
2577 }; | 2632 }; |
2578 var resp = convert.JSON.encode(buildOperation()); | 2633 var resp = convert.JSON.encode(buildOperation()); |
2579 return new async.Future.value(stringResponse(200, h, resp)); | 2634 return new async.Future.value(stringResponse(200, h, resp)); |
2580 }), true); | 2635 }), true); |
2581 res.patch(arg_request, arg_appsId, arg_servicesId, migrateTraffic: arg_mig
rateTraffic, mask: arg_mask).then(unittest.expectAsync(((api.Operation response)
{ | 2636 res.patch(arg_request, arg_appsId, arg_servicesId, migrateTraffic: arg_mig
rateTraffic, mask: arg_mask).then(unittest.expectAsync1(((api.Operation response
) { |
2582 checkOperation(response); | 2637 checkOperation(response); |
2583 }))); | 2638 }))); |
2584 }); | 2639 }); |
2585 | 2640 |
2586 }); | 2641 }); |
2587 | 2642 |
2588 | 2643 |
2589 unittest.group("resource-AppsServicesVersionsResourceApi", () { | 2644 unittest.group("resource-AppsServicesVersionsResourceApi", () { |
2590 unittest.test("method--create", () { | 2645 unittest.test("method--create", () { |
2591 | 2646 |
2592 var mock = new HttpServerMock(); | 2647 var mock = new HttpServerMock(); |
2593 api.AppsServicesVersionsResourceApi res = new api.AppengineApi(mock).apps.
services.versions; | 2648 api.AppsServicesVersionsResourceApi res = new api.AppengineApi(mock).apps.
services.versions; |
2594 var arg_request = buildVersion(); | 2649 var arg_request = buildVersion(); |
2595 var arg_appsId = "foo"; | 2650 var arg_appsId = "foo"; |
2596 var arg_servicesId = "foo"; | 2651 var arg_servicesId = "foo"; |
2597 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2652 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2598 var obj = new api.Version.fromJson(json); | 2653 var obj = new api.Version.fromJson(json); |
2599 checkVersion(obj); | 2654 checkVersion(obj); |
2600 | 2655 |
2601 var path = (req.url).path; | 2656 var path = (req.url).path; |
2602 var pathOffset = 0; | 2657 var pathOffset = 0; |
2603 var index; | 2658 var index; |
2604 var subPart; | 2659 var subPart; |
2605 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2660 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2606 pathOffset += 1; | 2661 pathOffset += 1; |
2607 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); | 2662 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); |
(...skipping 30 matching lines...) Expand all Loading... |
2638 } | 2693 } |
2639 } | 2694 } |
2640 | 2695 |
2641 | 2696 |
2642 var h = { | 2697 var h = { |
2643 "content-type" : "application/json; charset=utf-8", | 2698 "content-type" : "application/json; charset=utf-8", |
2644 }; | 2699 }; |
2645 var resp = convert.JSON.encode(buildOperation()); | 2700 var resp = convert.JSON.encode(buildOperation()); |
2646 return new async.Future.value(stringResponse(200, h, resp)); | 2701 return new async.Future.value(stringResponse(200, h, resp)); |
2647 }), true); | 2702 }), true); |
2648 res.create(arg_request, arg_appsId, arg_servicesId).then(unittest.expectAs
ync(((api.Operation response) { | 2703 res.create(arg_request, arg_appsId, arg_servicesId).then(unittest.expectAs
ync1(((api.Operation response) { |
2649 checkOperation(response); | 2704 checkOperation(response); |
2650 }))); | 2705 }))); |
2651 }); | 2706 }); |
2652 | 2707 |
2653 unittest.test("method--delete", () { | 2708 unittest.test("method--delete", () { |
2654 | 2709 |
2655 var mock = new HttpServerMock(); | 2710 var mock = new HttpServerMock(); |
2656 api.AppsServicesVersionsResourceApi res = new api.AppengineApi(mock).apps.
services.versions; | 2711 api.AppsServicesVersionsResourceApi res = new api.AppengineApi(mock).apps.
services.versions; |
2657 var arg_appsId = "foo"; | 2712 var arg_appsId = "foo"; |
2658 var arg_servicesId = "foo"; | 2713 var arg_servicesId = "foo"; |
2659 var arg_versionsId = "foo"; | 2714 var arg_versionsId = "foo"; |
2660 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2715 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2661 var path = (req.url).path; | 2716 var path = (req.url).path; |
2662 var pathOffset = 0; | 2717 var pathOffset = 0; |
2663 var index; | 2718 var index; |
2664 var subPart; | 2719 var subPart; |
2665 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2720 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2666 pathOffset += 1; | 2721 pathOffset += 1; |
2667 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); | 2722 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); |
2668 pathOffset += 13; | 2723 pathOffset += 13; |
2669 index = path.indexOf("/services/", pathOffset); | 2724 index = path.indexOf("/services/", pathOffset); |
2670 unittest.expect(index >= 0, unittest.isTrue); | 2725 unittest.expect(index >= 0, unittest.isTrue); |
(...skipping 30 matching lines...) Expand all Loading... |
2701 } | 2756 } |
2702 } | 2757 } |
2703 | 2758 |
2704 | 2759 |
2705 var h = { | 2760 var h = { |
2706 "content-type" : "application/json; charset=utf-8", | 2761 "content-type" : "application/json; charset=utf-8", |
2707 }; | 2762 }; |
2708 var resp = convert.JSON.encode(buildOperation()); | 2763 var resp = convert.JSON.encode(buildOperation()); |
2709 return new async.Future.value(stringResponse(200, h, resp)); | 2764 return new async.Future.value(stringResponse(200, h, resp)); |
2710 }), true); | 2765 }), true); |
2711 res.delete(arg_appsId, arg_servicesId, arg_versionsId).then(unittest.expec
tAsync(((api.Operation response) { | 2766 res.delete(arg_appsId, arg_servicesId, arg_versionsId).then(unittest.expec
tAsync1(((api.Operation response) { |
2712 checkOperation(response); | 2767 checkOperation(response); |
2713 }))); | 2768 }))); |
2714 }); | 2769 }); |
2715 | 2770 |
2716 unittest.test("method--get", () { | 2771 unittest.test("method--get", () { |
2717 | 2772 |
2718 var mock = new HttpServerMock(); | 2773 var mock = new HttpServerMock(); |
2719 api.AppsServicesVersionsResourceApi res = new api.AppengineApi(mock).apps.
services.versions; | 2774 api.AppsServicesVersionsResourceApi res = new api.AppengineApi(mock).apps.
services.versions; |
2720 var arg_appsId = "foo"; | 2775 var arg_appsId = "foo"; |
2721 var arg_servicesId = "foo"; | 2776 var arg_servicesId = "foo"; |
2722 var arg_versionsId = "foo"; | 2777 var arg_versionsId = "foo"; |
2723 var arg_view = "foo"; | 2778 var arg_view = "foo"; |
2724 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2779 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2725 var path = (req.url).path; | 2780 var path = (req.url).path; |
2726 var pathOffset = 0; | 2781 var pathOffset = 0; |
2727 var index; | 2782 var index; |
2728 var subPart; | 2783 var subPart; |
2729 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2784 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2730 pathOffset += 1; | 2785 pathOffset += 1; |
2731 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); | 2786 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); |
2732 pathOffset += 13; | 2787 pathOffset += 13; |
2733 index = path.indexOf("/services/", pathOffset); | 2788 index = path.indexOf("/services/", pathOffset); |
2734 unittest.expect(index >= 0, unittest.isTrue); | 2789 unittest.expect(index >= 0, unittest.isTrue); |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2766 } | 2821 } |
2767 unittest.expect(queryMap["view"].first, unittest.equals(arg_view)); | 2822 unittest.expect(queryMap["view"].first, unittest.equals(arg_view)); |
2768 | 2823 |
2769 | 2824 |
2770 var h = { | 2825 var h = { |
2771 "content-type" : "application/json; charset=utf-8", | 2826 "content-type" : "application/json; charset=utf-8", |
2772 }; | 2827 }; |
2773 var resp = convert.JSON.encode(buildVersion()); | 2828 var resp = convert.JSON.encode(buildVersion()); |
2774 return new async.Future.value(stringResponse(200, h, resp)); | 2829 return new async.Future.value(stringResponse(200, h, resp)); |
2775 }), true); | 2830 }), true); |
2776 res.get(arg_appsId, arg_servicesId, arg_versionsId, view: arg_view).then(u
nittest.expectAsync(((api.Version response) { | 2831 res.get(arg_appsId, arg_servicesId, arg_versionsId, view: arg_view).then(u
nittest.expectAsync1(((api.Version response) { |
2777 checkVersion(response); | 2832 checkVersion(response); |
2778 }))); | 2833 }))); |
2779 }); | 2834 }); |
2780 | 2835 |
2781 unittest.test("method--list", () { | 2836 unittest.test("method--list", () { |
2782 | 2837 |
2783 var mock = new HttpServerMock(); | 2838 var mock = new HttpServerMock(); |
2784 api.AppsServicesVersionsResourceApi res = new api.AppengineApi(mock).apps.
services.versions; | 2839 api.AppsServicesVersionsResourceApi res = new api.AppengineApi(mock).apps.
services.versions; |
2785 var arg_appsId = "foo"; | 2840 var arg_appsId = "foo"; |
2786 var arg_servicesId = "foo"; | 2841 var arg_servicesId = "foo"; |
2787 var arg_pageToken = "foo"; | 2842 var arg_pageToken = "foo"; |
2788 var arg_pageSize = 42; | 2843 var arg_pageSize = 42; |
2789 var arg_view = "foo"; | 2844 var arg_view = "foo"; |
2790 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2845 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2791 var path = (req.url).path; | 2846 var path = (req.url).path; |
2792 var pathOffset = 0; | 2847 var pathOffset = 0; |
2793 var index; | 2848 var index; |
2794 var subPart; | 2849 var subPart; |
2795 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2850 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2796 pathOffset += 1; | 2851 pathOffset += 1; |
2797 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); | 2852 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); |
2798 pathOffset += 13; | 2853 pathOffset += 13; |
2799 index = path.indexOf("/services/", pathOffset); | 2854 index = path.indexOf("/services/", pathOffset); |
2800 unittest.expect(index >= 0, unittest.isTrue); | 2855 unittest.expect(index >= 0, unittest.isTrue); |
(...skipping 30 matching lines...) Expand all Loading... |
2831 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); | 2886 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); |
2832 unittest.expect(queryMap["view"].first, unittest.equals(arg_view)); | 2887 unittest.expect(queryMap["view"].first, unittest.equals(arg_view)); |
2833 | 2888 |
2834 | 2889 |
2835 var h = { | 2890 var h = { |
2836 "content-type" : "application/json; charset=utf-8", | 2891 "content-type" : "application/json; charset=utf-8", |
2837 }; | 2892 }; |
2838 var resp = convert.JSON.encode(buildListVersionsResponse()); | 2893 var resp = convert.JSON.encode(buildListVersionsResponse()); |
2839 return new async.Future.value(stringResponse(200, h, resp)); | 2894 return new async.Future.value(stringResponse(200, h, resp)); |
2840 }), true); | 2895 }), true); |
2841 res.list(arg_appsId, arg_servicesId, pageToken: arg_pageToken, pageSize: a
rg_pageSize, view: arg_view).then(unittest.expectAsync(((api.ListVersionsRespons
e response) { | 2896 res.list(arg_appsId, arg_servicesId, pageToken: arg_pageToken, pageSize: a
rg_pageSize, view: arg_view).then(unittest.expectAsync1(((api.ListVersionsRespon
se response) { |
2842 checkListVersionsResponse(response); | 2897 checkListVersionsResponse(response); |
2843 }))); | 2898 }))); |
2844 }); | 2899 }); |
2845 | 2900 |
2846 unittest.test("method--patch", () { | 2901 unittest.test("method--patch", () { |
2847 | 2902 |
2848 var mock = new HttpServerMock(); | 2903 var mock = new HttpServerMock(); |
2849 api.AppsServicesVersionsResourceApi res = new api.AppengineApi(mock).apps.
services.versions; | 2904 api.AppsServicesVersionsResourceApi res = new api.AppengineApi(mock).apps.
services.versions; |
2850 var arg_request = buildVersion(); | 2905 var arg_request = buildVersion(); |
2851 var arg_appsId = "foo"; | 2906 var arg_appsId = "foo"; |
2852 var arg_servicesId = "foo"; | 2907 var arg_servicesId = "foo"; |
2853 var arg_versionsId = "foo"; | 2908 var arg_versionsId = "foo"; |
2854 var arg_mask = "foo"; | 2909 var arg_mask = "foo"; |
2855 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2910 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2856 var obj = new api.Version.fromJson(json); | 2911 var obj = new api.Version.fromJson(json); |
2857 checkVersion(obj); | 2912 checkVersion(obj); |
2858 | 2913 |
2859 var path = (req.url).path; | 2914 var path = (req.url).path; |
2860 var pathOffset = 0; | 2915 var pathOffset = 0; |
2861 var index; | 2916 var index; |
2862 var subPart; | 2917 var subPart; |
2863 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2918 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2864 pathOffset += 1; | 2919 pathOffset += 1; |
2865 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); | 2920 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2900 } | 2955 } |
2901 unittest.expect(queryMap["mask"].first, unittest.equals(arg_mask)); | 2956 unittest.expect(queryMap["mask"].first, unittest.equals(arg_mask)); |
2902 | 2957 |
2903 | 2958 |
2904 var h = { | 2959 var h = { |
2905 "content-type" : "application/json; charset=utf-8", | 2960 "content-type" : "application/json; charset=utf-8", |
2906 }; | 2961 }; |
2907 var resp = convert.JSON.encode(buildOperation()); | 2962 var resp = convert.JSON.encode(buildOperation()); |
2908 return new async.Future.value(stringResponse(200, h, resp)); | 2963 return new async.Future.value(stringResponse(200, h, resp)); |
2909 }), true); | 2964 }), true); |
2910 res.patch(arg_request, arg_appsId, arg_servicesId, arg_versionsId, mask: a
rg_mask).then(unittest.expectAsync(((api.Operation response) { | 2965 res.patch(arg_request, arg_appsId, arg_servicesId, arg_versionsId, mask: a
rg_mask).then(unittest.expectAsync1(((api.Operation response) { |
2911 checkOperation(response); | 2966 checkOperation(response); |
2912 }))); | 2967 }))); |
2913 }); | 2968 }); |
2914 | 2969 |
2915 }); | 2970 }); |
2916 | 2971 |
2917 | 2972 |
2918 unittest.group("resource-AppsServicesVersionsInstancesResourceApi", () { | 2973 unittest.group("resource-AppsServicesVersionsInstancesResourceApi", () { |
2919 unittest.test("method--debug", () { | 2974 unittest.test("method--debug", () { |
2920 | 2975 |
2921 var mock = new HttpServerMock(); | 2976 var mock = new HttpServerMock(); |
2922 api.AppsServicesVersionsInstancesResourceApi res = new api.AppengineApi(mo
ck).apps.services.versions.instances; | 2977 api.AppsServicesVersionsInstancesResourceApi res = new api.AppengineApi(mo
ck).apps.services.versions.instances; |
2923 var arg_request = buildDebugInstanceRequest(); | 2978 var arg_request = buildDebugInstanceRequest(); |
2924 var arg_appsId = "foo"; | 2979 var arg_appsId = "foo"; |
2925 var arg_servicesId = "foo"; | 2980 var arg_servicesId = "foo"; |
2926 var arg_versionsId = "foo"; | 2981 var arg_versionsId = "foo"; |
2927 var arg_instancesId = "foo"; | 2982 var arg_instancesId = "foo"; |
2928 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2983 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
2929 var obj = new api.DebugInstanceRequest.fromJson(json); | 2984 var obj = new api.DebugInstanceRequest.fromJson(json); |
2930 checkDebugInstanceRequest(obj); | 2985 checkDebugInstanceRequest(obj); |
2931 | 2986 |
2932 var path = (req.url).path; | 2987 var path = (req.url).path; |
2933 var pathOffset = 0; | 2988 var pathOffset = 0; |
2934 var index; | 2989 var index; |
2935 var subPart; | 2990 var subPart; |
2936 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2991 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2937 pathOffset += 1; | 2992 pathOffset += 1; |
2938 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); | 2993 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2983 } | 3038 } |
2984 } | 3039 } |
2985 | 3040 |
2986 | 3041 |
2987 var h = { | 3042 var h = { |
2988 "content-type" : "application/json; charset=utf-8", | 3043 "content-type" : "application/json; charset=utf-8", |
2989 }; | 3044 }; |
2990 var resp = convert.JSON.encode(buildOperation()); | 3045 var resp = convert.JSON.encode(buildOperation()); |
2991 return new async.Future.value(stringResponse(200, h, resp)); | 3046 return new async.Future.value(stringResponse(200, h, resp)); |
2992 }), true); | 3047 }), true); |
2993 res.debug(arg_request, arg_appsId, arg_servicesId, arg_versionsId, arg_ins
tancesId).then(unittest.expectAsync(((api.Operation response) { | 3048 res.debug(arg_request, arg_appsId, arg_servicesId, arg_versionsId, arg_ins
tancesId).then(unittest.expectAsync1(((api.Operation response) { |
2994 checkOperation(response); | 3049 checkOperation(response); |
2995 }))); | 3050 }))); |
2996 }); | 3051 }); |
2997 | 3052 |
2998 unittest.test("method--delete", () { | 3053 unittest.test("method--delete", () { |
2999 | 3054 |
3000 var mock = new HttpServerMock(); | 3055 var mock = new HttpServerMock(); |
3001 api.AppsServicesVersionsInstancesResourceApi res = new api.AppengineApi(mo
ck).apps.services.versions.instances; | 3056 api.AppsServicesVersionsInstancesResourceApi res = new api.AppengineApi(mo
ck).apps.services.versions.instances; |
3002 var arg_appsId = "foo"; | 3057 var arg_appsId = "foo"; |
3003 var arg_servicesId = "foo"; | 3058 var arg_servicesId = "foo"; |
3004 var arg_versionsId = "foo"; | 3059 var arg_versionsId = "foo"; |
3005 var arg_instancesId = "foo"; | 3060 var arg_instancesId = "foo"; |
3006 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3061 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3007 var path = (req.url).path; | 3062 var path = (req.url).path; |
3008 var pathOffset = 0; | 3063 var pathOffset = 0; |
3009 var index; | 3064 var index; |
3010 var subPart; | 3065 var subPart; |
3011 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3066 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3012 pathOffset += 1; | 3067 pathOffset += 1; |
3013 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); | 3068 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); |
3014 pathOffset += 13; | 3069 pathOffset += 13; |
3015 index = path.indexOf("/services/", pathOffset); | 3070 index = path.indexOf("/services/", pathOffset); |
3016 unittest.expect(index >= 0, unittest.isTrue); | 3071 unittest.expect(index >= 0, unittest.isTrue); |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3054 } | 3109 } |
3055 } | 3110 } |
3056 | 3111 |
3057 | 3112 |
3058 var h = { | 3113 var h = { |
3059 "content-type" : "application/json; charset=utf-8", | 3114 "content-type" : "application/json; charset=utf-8", |
3060 }; | 3115 }; |
3061 var resp = convert.JSON.encode(buildOperation()); | 3116 var resp = convert.JSON.encode(buildOperation()); |
3062 return new async.Future.value(stringResponse(200, h, resp)); | 3117 return new async.Future.value(stringResponse(200, h, resp)); |
3063 }), true); | 3118 }), true); |
3064 res.delete(arg_appsId, arg_servicesId, arg_versionsId, arg_instancesId).th
en(unittest.expectAsync(((api.Operation response) { | 3119 res.delete(arg_appsId, arg_servicesId, arg_versionsId, arg_instancesId).th
en(unittest.expectAsync1(((api.Operation response) { |
3065 checkOperation(response); | 3120 checkOperation(response); |
3066 }))); | 3121 }))); |
3067 }); | 3122 }); |
3068 | 3123 |
3069 unittest.test("method--get", () { | 3124 unittest.test("method--get", () { |
3070 | 3125 |
3071 var mock = new HttpServerMock(); | 3126 var mock = new HttpServerMock(); |
3072 api.AppsServicesVersionsInstancesResourceApi res = new api.AppengineApi(mo
ck).apps.services.versions.instances; | 3127 api.AppsServicesVersionsInstancesResourceApi res = new api.AppengineApi(mo
ck).apps.services.versions.instances; |
3073 var arg_appsId = "foo"; | 3128 var arg_appsId = "foo"; |
3074 var arg_servicesId = "foo"; | 3129 var arg_servicesId = "foo"; |
3075 var arg_versionsId = "foo"; | 3130 var arg_versionsId = "foo"; |
3076 var arg_instancesId = "foo"; | 3131 var arg_instancesId = "foo"; |
3077 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3132 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3078 var path = (req.url).path; | 3133 var path = (req.url).path; |
3079 var pathOffset = 0; | 3134 var pathOffset = 0; |
3080 var index; | 3135 var index; |
3081 var subPart; | 3136 var subPart; |
3082 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3137 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3083 pathOffset += 1; | 3138 pathOffset += 1; |
3084 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); | 3139 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); |
3085 pathOffset += 13; | 3140 pathOffset += 13; |
3086 index = path.indexOf("/services/", pathOffset); | 3141 index = path.indexOf("/services/", pathOffset); |
3087 unittest.expect(index >= 0, unittest.isTrue); | 3142 unittest.expect(index >= 0, unittest.isTrue); |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3125 } | 3180 } |
3126 } | 3181 } |
3127 | 3182 |
3128 | 3183 |
3129 var h = { | 3184 var h = { |
3130 "content-type" : "application/json; charset=utf-8", | 3185 "content-type" : "application/json; charset=utf-8", |
3131 }; | 3186 }; |
3132 var resp = convert.JSON.encode(buildInstance()); | 3187 var resp = convert.JSON.encode(buildInstance()); |
3133 return new async.Future.value(stringResponse(200, h, resp)); | 3188 return new async.Future.value(stringResponse(200, h, resp)); |
3134 }), true); | 3189 }), true); |
3135 res.get(arg_appsId, arg_servicesId, arg_versionsId, arg_instancesId).then(
unittest.expectAsync(((api.Instance response) { | 3190 res.get(arg_appsId, arg_servicesId, arg_versionsId, arg_instancesId).then(
unittest.expectAsync1(((api.Instance response) { |
3136 checkInstance(response); | 3191 checkInstance(response); |
3137 }))); | 3192 }))); |
3138 }); | 3193 }); |
3139 | 3194 |
3140 unittest.test("method--list", () { | 3195 unittest.test("method--list", () { |
3141 | 3196 |
3142 var mock = new HttpServerMock(); | 3197 var mock = new HttpServerMock(); |
3143 api.AppsServicesVersionsInstancesResourceApi res = new api.AppengineApi(mo
ck).apps.services.versions.instances; | 3198 api.AppsServicesVersionsInstancesResourceApi res = new api.AppengineApi(mo
ck).apps.services.versions.instances; |
3144 var arg_appsId = "foo"; | 3199 var arg_appsId = "foo"; |
3145 var arg_servicesId = "foo"; | 3200 var arg_servicesId = "foo"; |
3146 var arg_versionsId = "foo"; | 3201 var arg_versionsId = "foo"; |
3147 var arg_pageToken = "foo"; | 3202 var arg_pageToken = "foo"; |
3148 var arg_pageSize = 42; | 3203 var arg_pageSize = 42; |
3149 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3204 mock.register(unittest.expectAsync2((http.BaseRequest req, json) { |
3150 var path = (req.url).path; | 3205 var path = (req.url).path; |
3151 var pathOffset = 0; | 3206 var pathOffset = 0; |
3152 var index; | 3207 var index; |
3153 var subPart; | 3208 var subPart; |
3154 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3209 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3155 pathOffset += 1; | 3210 pathOffset += 1; |
3156 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); | 3211 unittest.expect(path.substring(pathOffset, pathOffset + 13), unittest.eq
uals("v1beta5/apps/")); |
3157 pathOffset += 13; | 3212 pathOffset += 13; |
3158 index = path.indexOf("/services/", pathOffset); | 3213 index = path.indexOf("/services/", pathOffset); |
3159 unittest.expect(index >= 0, unittest.isTrue); | 3214 unittest.expect(index >= 0, unittest.isTrue); |
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3196 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); | 3251 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); |
3197 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); | 3252 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); |
3198 | 3253 |
3199 | 3254 |
3200 var h = { | 3255 var h = { |
3201 "content-type" : "application/json; charset=utf-8", | 3256 "content-type" : "application/json; charset=utf-8", |
3202 }; | 3257 }; |
3203 var resp = convert.JSON.encode(buildListInstancesResponse()); | 3258 var resp = convert.JSON.encode(buildListInstancesResponse()); |
3204 return new async.Future.value(stringResponse(200, h, resp)); | 3259 return new async.Future.value(stringResponse(200, h, resp)); |
3205 }), true); | 3260 }), true); |
3206 res.list(arg_appsId, arg_servicesId, arg_versionsId, pageToken: arg_pageTo
ken, pageSize: arg_pageSize).then(unittest.expectAsync(((api.ListInstancesRespon
se response) { | 3261 res.list(arg_appsId, arg_servicesId, arg_versionsId, pageToken: arg_pageTo
ken, pageSize: arg_pageSize).then(unittest.expectAsync1(((api.ListInstancesRespo
nse response) { |
3207 checkListInstancesResponse(response); | 3262 checkListInstancesResponse(response); |
3208 }))); | 3263 }))); |
3209 }); | 3264 }); |
3210 | 3265 |
3211 }); | 3266 }); |
3212 | 3267 |
3213 | 3268 |
3214 } | 3269 } |
3215 | 3270 |
OLD | NEW |