Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(44)

Side by Side Diff: generated/googleapis_beta/test/clouderrorreporting/v1beta1_test.dart

Issue 2485703002: Api-roll 42: 2016-11-08 (Closed)
Patch Set: Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 library googleapis_beta.clouderrorreporting.v1beta1.test; 1 library googleapis_beta.clouderrorreporting.v1beta1.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:unittest/unittest.dart' as unittest;
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 buildCounterErrorEvent++; 109 buildCounterErrorEvent++;
110 if (buildCounterErrorEvent < 3) { 110 if (buildCounterErrorEvent < 3) {
111 checkErrorContext(o.context); 111 checkErrorContext(o.context);
112 unittest.expect(o.eventTime, unittest.equals('foo')); 112 unittest.expect(o.eventTime, unittest.equals('foo'));
113 unittest.expect(o.message, unittest.equals('foo')); 113 unittest.expect(o.message, unittest.equals('foo'));
114 checkServiceContext(o.serviceContext); 114 checkServiceContext(o.serviceContext);
115 } 115 }
116 buildCounterErrorEvent--; 116 buildCounterErrorEvent--;
117 } 117 }
118 118
119 buildUnnamed3745() { 119 buildUnnamed3582() {
120 var o = new core.List<api.TrackingIssue>(); 120 var o = new core.List<api.TrackingIssue>();
121 o.add(buildTrackingIssue()); 121 o.add(buildTrackingIssue());
122 o.add(buildTrackingIssue()); 122 o.add(buildTrackingIssue());
123 return o; 123 return o;
124 } 124 }
125 125
126 checkUnnamed3745(core.List<api.TrackingIssue> o) { 126 checkUnnamed3582(core.List<api.TrackingIssue> o) {
127 unittest.expect(o, unittest.hasLength(2)); 127 unittest.expect(o, unittest.hasLength(2));
128 checkTrackingIssue(o[0]); 128 checkTrackingIssue(o[0]);
129 checkTrackingIssue(o[1]); 129 checkTrackingIssue(o[1]);
130 } 130 }
131 131
132 core.int buildCounterErrorGroup = 0; 132 core.int buildCounterErrorGroup = 0;
133 buildErrorGroup() { 133 buildErrorGroup() {
134 var o = new api.ErrorGroup(); 134 var o = new api.ErrorGroup();
135 buildCounterErrorGroup++; 135 buildCounterErrorGroup++;
136 if (buildCounterErrorGroup < 3) { 136 if (buildCounterErrorGroup < 3) {
137 o.groupId = "foo"; 137 o.groupId = "foo";
138 o.name = "foo"; 138 o.name = "foo";
139 o.trackingIssues = buildUnnamed3745(); 139 o.trackingIssues = buildUnnamed3582();
140 } 140 }
141 buildCounterErrorGroup--; 141 buildCounterErrorGroup--;
142 return o; 142 return o;
143 } 143 }
144 144
145 checkErrorGroup(api.ErrorGroup o) { 145 checkErrorGroup(api.ErrorGroup o) {
146 buildCounterErrorGroup++; 146 buildCounterErrorGroup++;
147 if (buildCounterErrorGroup < 3) { 147 if (buildCounterErrorGroup < 3) {
148 unittest.expect(o.groupId, unittest.equals('foo')); 148 unittest.expect(o.groupId, unittest.equals('foo'));
149 unittest.expect(o.name, unittest.equals('foo')); 149 unittest.expect(o.name, unittest.equals('foo'));
150 checkUnnamed3745(o.trackingIssues); 150 checkUnnamed3582(o.trackingIssues);
151 } 151 }
152 buildCounterErrorGroup--; 152 buildCounterErrorGroup--;
153 } 153 }
154 154
155 buildUnnamed3746() { 155 buildUnnamed3583() {
156 var o = new core.List<api.ServiceContext>(); 156 var o = new core.List<api.ServiceContext>();
157 o.add(buildServiceContext()); 157 o.add(buildServiceContext());
158 o.add(buildServiceContext()); 158 o.add(buildServiceContext());
159 return o; 159 return o;
160 } 160 }
161 161
162 checkUnnamed3746(core.List<api.ServiceContext> o) { 162 checkUnnamed3583(core.List<api.ServiceContext> o) {
163 unittest.expect(o, unittest.hasLength(2)); 163 unittest.expect(o, unittest.hasLength(2));
164 checkServiceContext(o[0]); 164 checkServiceContext(o[0]);
165 checkServiceContext(o[1]); 165 checkServiceContext(o[1]);
166 } 166 }
167 167
168 buildUnnamed3747() { 168 buildUnnamed3584() {
169 var o = new core.List<api.TimedCount>(); 169 var o = new core.List<api.TimedCount>();
170 o.add(buildTimedCount()); 170 o.add(buildTimedCount());
171 o.add(buildTimedCount()); 171 o.add(buildTimedCount());
172 return o; 172 return o;
173 } 173 }
174 174
175 checkUnnamed3747(core.List<api.TimedCount> o) { 175 checkUnnamed3584(core.List<api.TimedCount> o) {
176 unittest.expect(o, unittest.hasLength(2)); 176 unittest.expect(o, unittest.hasLength(2));
177 checkTimedCount(o[0]); 177 checkTimedCount(o[0]);
178 checkTimedCount(o[1]); 178 checkTimedCount(o[1]);
179 } 179 }
180 180
181 core.int buildCounterErrorGroupStats = 0; 181 core.int buildCounterErrorGroupStats = 0;
182 buildErrorGroupStats() { 182 buildErrorGroupStats() {
183 var o = new api.ErrorGroupStats(); 183 var o = new api.ErrorGroupStats();
184 buildCounterErrorGroupStats++; 184 buildCounterErrorGroupStats++;
185 if (buildCounterErrorGroupStats < 3) { 185 if (buildCounterErrorGroupStats < 3) {
186 o.affectedServices = buildUnnamed3746(); 186 o.affectedServices = buildUnnamed3583();
187 o.affectedUsersCount = "foo"; 187 o.affectedUsersCount = "foo";
188 o.count = "foo"; 188 o.count = "foo";
189 o.firstSeenTime = "foo"; 189 o.firstSeenTime = "foo";
190 o.group = buildErrorGroup(); 190 o.group = buildErrorGroup();
191 o.lastSeenTime = "foo"; 191 o.lastSeenTime = "foo";
192 o.numAffectedServices = 42; 192 o.numAffectedServices = 42;
193 o.representative = buildErrorEvent(); 193 o.representative = buildErrorEvent();
194 o.timedCounts = buildUnnamed3747(); 194 o.timedCounts = buildUnnamed3584();
195 } 195 }
196 buildCounterErrorGroupStats--; 196 buildCounterErrorGroupStats--;
197 return o; 197 return o;
198 } 198 }
199 199
200 checkErrorGroupStats(api.ErrorGroupStats o) { 200 checkErrorGroupStats(api.ErrorGroupStats o) {
201 buildCounterErrorGroupStats++; 201 buildCounterErrorGroupStats++;
202 if (buildCounterErrorGroupStats < 3) { 202 if (buildCounterErrorGroupStats < 3) {
203 checkUnnamed3746(o.affectedServices); 203 checkUnnamed3583(o.affectedServices);
204 unittest.expect(o.affectedUsersCount, unittest.equals('foo')); 204 unittest.expect(o.affectedUsersCount, unittest.equals('foo'));
205 unittest.expect(o.count, unittest.equals('foo')); 205 unittest.expect(o.count, unittest.equals('foo'));
206 unittest.expect(o.firstSeenTime, unittest.equals('foo')); 206 unittest.expect(o.firstSeenTime, unittest.equals('foo'));
207 checkErrorGroup(o.group); 207 checkErrorGroup(o.group);
208 unittest.expect(o.lastSeenTime, unittest.equals('foo')); 208 unittest.expect(o.lastSeenTime, unittest.equals('foo'));
209 unittest.expect(o.numAffectedServices, unittest.equals(42)); 209 unittest.expect(o.numAffectedServices, unittest.equals(42));
210 checkErrorEvent(o.representative); 210 checkErrorEvent(o.representative);
211 checkUnnamed3747(o.timedCounts); 211 checkUnnamed3584(o.timedCounts);
212 } 212 }
213 buildCounterErrorGroupStats--; 213 buildCounterErrorGroupStats--;
214 } 214 }
215 215
216 core.int buildCounterHttpRequestContext = 0; 216 core.int buildCounterHttpRequestContext = 0;
217 buildHttpRequestContext() { 217 buildHttpRequestContext() {
218 var o = new api.HttpRequestContext(); 218 var o = new api.HttpRequestContext();
219 buildCounterHttpRequestContext++; 219 buildCounterHttpRequestContext++;
220 if (buildCounterHttpRequestContext < 3) { 220 if (buildCounterHttpRequestContext < 3) {
221 o.method = "foo"; 221 o.method = "foo";
(...skipping 13 matching lines...) Expand all
235 unittest.expect(o.method, unittest.equals('foo')); 235 unittest.expect(o.method, unittest.equals('foo'));
236 unittest.expect(o.referrer, unittest.equals('foo')); 236 unittest.expect(o.referrer, unittest.equals('foo'));
237 unittest.expect(o.remoteIp, unittest.equals('foo')); 237 unittest.expect(o.remoteIp, unittest.equals('foo'));
238 unittest.expect(o.responseStatusCode, unittest.equals(42)); 238 unittest.expect(o.responseStatusCode, unittest.equals(42));
239 unittest.expect(o.url, unittest.equals('foo')); 239 unittest.expect(o.url, unittest.equals('foo'));
240 unittest.expect(o.userAgent, unittest.equals('foo')); 240 unittest.expect(o.userAgent, unittest.equals('foo'));
241 } 241 }
242 buildCounterHttpRequestContext--; 242 buildCounterHttpRequestContext--;
243 } 243 }
244 244
245 buildUnnamed3748() { 245 buildUnnamed3585() {
246 var o = new core.List<api.ErrorEvent>(); 246 var o = new core.List<api.ErrorEvent>();
247 o.add(buildErrorEvent()); 247 o.add(buildErrorEvent());
248 o.add(buildErrorEvent()); 248 o.add(buildErrorEvent());
249 return o; 249 return o;
250 } 250 }
251 251
252 checkUnnamed3748(core.List<api.ErrorEvent> o) { 252 checkUnnamed3585(core.List<api.ErrorEvent> o) {
253 unittest.expect(o, unittest.hasLength(2)); 253 unittest.expect(o, unittest.hasLength(2));
254 checkErrorEvent(o[0]); 254 checkErrorEvent(o[0]);
255 checkErrorEvent(o[1]); 255 checkErrorEvent(o[1]);
256 } 256 }
257 257
258 core.int buildCounterListEventsResponse = 0; 258 core.int buildCounterListEventsResponse = 0;
259 buildListEventsResponse() { 259 buildListEventsResponse() {
260 var o = new api.ListEventsResponse(); 260 var o = new api.ListEventsResponse();
261 buildCounterListEventsResponse++; 261 buildCounterListEventsResponse++;
262 if (buildCounterListEventsResponse < 3) { 262 if (buildCounterListEventsResponse < 3) {
263 o.errorEvents = buildUnnamed3748(); 263 o.errorEvents = buildUnnamed3585();
264 o.nextPageToken = "foo"; 264 o.nextPageToken = "foo";
265 o.timeRangeBegin = "foo";
265 } 266 }
266 buildCounterListEventsResponse--; 267 buildCounterListEventsResponse--;
267 return o; 268 return o;
268 } 269 }
269 270
270 checkListEventsResponse(api.ListEventsResponse o) { 271 checkListEventsResponse(api.ListEventsResponse o) {
271 buildCounterListEventsResponse++; 272 buildCounterListEventsResponse++;
272 if (buildCounterListEventsResponse < 3) { 273 if (buildCounterListEventsResponse < 3) {
273 checkUnnamed3748(o.errorEvents); 274 checkUnnamed3585(o.errorEvents);
274 unittest.expect(o.nextPageToken, unittest.equals('foo')); 275 unittest.expect(o.nextPageToken, unittest.equals('foo'));
276 unittest.expect(o.timeRangeBegin, unittest.equals('foo'));
275 } 277 }
276 buildCounterListEventsResponse--; 278 buildCounterListEventsResponse--;
277 } 279 }
278 280
279 buildUnnamed3749() { 281 buildUnnamed3586() {
280 var o = new core.List<api.ErrorGroupStats>(); 282 var o = new core.List<api.ErrorGroupStats>();
281 o.add(buildErrorGroupStats()); 283 o.add(buildErrorGroupStats());
282 o.add(buildErrorGroupStats()); 284 o.add(buildErrorGroupStats());
283 return o; 285 return o;
284 } 286 }
285 287
286 checkUnnamed3749(core.List<api.ErrorGroupStats> o) { 288 checkUnnamed3586(core.List<api.ErrorGroupStats> o) {
287 unittest.expect(o, unittest.hasLength(2)); 289 unittest.expect(o, unittest.hasLength(2));
288 checkErrorGroupStats(o[0]); 290 checkErrorGroupStats(o[0]);
289 checkErrorGroupStats(o[1]); 291 checkErrorGroupStats(o[1]);
290 } 292 }
291 293
292 core.int buildCounterListGroupStatsResponse = 0; 294 core.int buildCounterListGroupStatsResponse = 0;
293 buildListGroupStatsResponse() { 295 buildListGroupStatsResponse() {
294 var o = new api.ListGroupStatsResponse(); 296 var o = new api.ListGroupStatsResponse();
295 buildCounterListGroupStatsResponse++; 297 buildCounterListGroupStatsResponse++;
296 if (buildCounterListGroupStatsResponse < 3) { 298 if (buildCounterListGroupStatsResponse < 3) {
297 o.errorGroupStats = buildUnnamed3749(); 299 o.errorGroupStats = buildUnnamed3586();
298 o.nextPageToken = "foo"; 300 o.nextPageToken = "foo";
301 o.timeRangeBegin = "foo";
299 } 302 }
300 buildCounterListGroupStatsResponse--; 303 buildCounterListGroupStatsResponse--;
301 return o; 304 return o;
302 } 305 }
303 306
304 checkListGroupStatsResponse(api.ListGroupStatsResponse o) { 307 checkListGroupStatsResponse(api.ListGroupStatsResponse o) {
305 buildCounterListGroupStatsResponse++; 308 buildCounterListGroupStatsResponse++;
306 if (buildCounterListGroupStatsResponse < 3) { 309 if (buildCounterListGroupStatsResponse < 3) {
307 checkUnnamed3749(o.errorGroupStats); 310 checkUnnamed3586(o.errorGroupStats);
308 unittest.expect(o.nextPageToken, unittest.equals('foo')); 311 unittest.expect(o.nextPageToken, unittest.equals('foo'));
312 unittest.expect(o.timeRangeBegin, unittest.equals('foo'));
309 } 313 }
310 buildCounterListGroupStatsResponse--; 314 buildCounterListGroupStatsResponse--;
311 } 315 }
312 316
313 core.int buildCounterReportErrorEventResponse = 0; 317 core.int buildCounterReportErrorEventResponse = 0;
314 buildReportErrorEventResponse() { 318 buildReportErrorEventResponse() {
315 var o = new api.ReportErrorEventResponse(); 319 var o = new api.ReportErrorEventResponse();
316 buildCounterReportErrorEventResponse++; 320 buildCounterReportErrorEventResponse++;
317 if (buildCounterReportErrorEventResponse < 3) { 321 if (buildCounterReportErrorEventResponse < 3) {
318 } 322 }
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after
431 } 435 }
432 436
433 checkTrackingIssue(api.TrackingIssue o) { 437 checkTrackingIssue(api.TrackingIssue o) {
434 buildCounterTrackingIssue++; 438 buildCounterTrackingIssue++;
435 if (buildCounterTrackingIssue < 3) { 439 if (buildCounterTrackingIssue < 3) {
436 unittest.expect(o.url, unittest.equals('foo')); 440 unittest.expect(o.url, unittest.equals('foo'));
437 } 441 }
438 buildCounterTrackingIssue--; 442 buildCounterTrackingIssue--;
439 } 443 }
440 444
441 buildUnnamed3750() { 445 buildUnnamed3587() {
442 var o = new core.List<core.String>(); 446 var o = new core.List<core.String>();
443 o.add("foo"); 447 o.add("foo");
444 o.add("foo"); 448 o.add("foo");
445 return o; 449 return o;
446 } 450 }
447 451
448 checkUnnamed3750(core.List<core.String> o) { 452 checkUnnamed3587(core.List<core.String> o) {
449 unittest.expect(o, unittest.hasLength(2)); 453 unittest.expect(o, unittest.hasLength(2));
450 unittest.expect(o[0], unittest.equals('foo')); 454 unittest.expect(o[0], unittest.equals('foo'));
451 unittest.expect(o[1], unittest.equals('foo')); 455 unittest.expect(o[1], unittest.equals('foo'));
452 } 456 }
453 457
454 458
455 main() { 459 main() {
456 unittest.group("obj-schema-DeleteEventsResponse", () { 460 unittest.group("obj-schema-DeleteEventsResponse", () {
457 unittest.test("to-json--from-json", () { 461 unittest.test("to-json--from-json", () {
458 var o = buildDeleteEventsResponse(); 462 var o = buildDeleteEventsResponse();
(...skipping 281 matching lines...) Expand 10 before | Expand all | Expand 10 after
740 744
741 unittest.group("resource-ProjectsGroupStatsResourceApi", () { 745 unittest.group("resource-ProjectsGroupStatsResourceApi", () {
742 unittest.test("method--list", () { 746 unittest.test("method--list", () {
743 747
744 var mock = new HttpServerMock(); 748 var mock = new HttpServerMock();
745 api.ProjectsGroupStatsResourceApi res = new api.ClouderrorreportingApi(moc k).projects.groupStats; 749 api.ProjectsGroupStatsResourceApi res = new api.ClouderrorreportingApi(moc k).projects.groupStats;
746 var arg_projectName = "foo"; 750 var arg_projectName = "foo";
747 var arg_alignment = "foo"; 751 var arg_alignment = "foo";
748 var arg_timeRange_period = "foo"; 752 var arg_timeRange_period = "foo";
749 var arg_order = "foo"; 753 var arg_order = "foo";
750 var arg_groupId = buildUnnamed3750(); 754 var arg_groupId = buildUnnamed3587();
751 var arg_serviceFilter_service = "foo"; 755 var arg_serviceFilter_service = "foo";
752 var arg_alignmentTime = "foo"; 756 var arg_alignmentTime = "foo";
753 var arg_serviceFilter_version = "foo"; 757 var arg_serviceFilter_version = "foo";
754 var arg_pageSize = 42; 758 var arg_pageSize = 42;
755 var arg_timedCountDuration = "foo"; 759 var arg_timedCountDuration = "foo";
756 var arg_pageToken = "foo"; 760 var arg_pageToken = "foo";
757 mock.register(unittest.expectAsync((http.BaseRequest req, json) { 761 mock.register(unittest.expectAsync((http.BaseRequest req, json) {
758 var path = (req.url).path; 762 var path = (req.url).path;
759 var pathOffset = 0; 763 var pathOffset = 0;
760 var index; 764 var index;
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
900 res.update(arg_request, arg_name).then(unittest.expectAsync(((api.ErrorGro up response) { 904 res.update(arg_request, arg_name).then(unittest.expectAsync(((api.ErrorGro up response) {
901 checkErrorGroup(response); 905 checkErrorGroup(response);
902 }))); 906 })));
903 }); 907 });
904 908
905 }); 909 });
906 910
907 911
908 } 912 }
909 913
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698