OLD | NEW |
1 library googleapis.classroom.v1.test; | 1 library googleapis.classroom.v1.test; |
2 | 2 |
3 import "dart:core" as core; | 3 import "dart:core" as core; |
4 import "dart:collection" as collection; | 4 import "dart:collection" as collection; |
5 import "dart:async" as async; | 5 import "dart:async" as async; |
6 import "dart:convert" as convert; | 6 import "dart:convert" as convert; |
7 | 7 |
8 import 'package:http/http.dart' as http; | 8 import 'package:http/http.dart' as http; |
9 import 'package:http/testing.dart' as http_testing; | 9 import 'package:http/testing.dart' as http_testing; |
10 import 'package:unittest/unittest.dart' as unittest; | 10 import 'package:unittest/unittest.dart' as unittest; |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
63 } | 63 } |
64 | 64 |
65 checkAssignment(api.Assignment o) { | 65 checkAssignment(api.Assignment o) { |
66 buildCounterAssignment++; | 66 buildCounterAssignment++; |
67 if (buildCounterAssignment < 3) { | 67 if (buildCounterAssignment < 3) { |
68 checkDriveFolder(o.studentWorkFolder); | 68 checkDriveFolder(o.studentWorkFolder); |
69 } | 69 } |
70 buildCounterAssignment--; | 70 buildCounterAssignment--; |
71 } | 71 } |
72 | 72 |
73 buildUnnamed670() { | 73 buildUnnamed691() { |
74 var o = new core.List<api.Attachment>(); | 74 var o = new core.List<api.Attachment>(); |
75 o.add(buildAttachment()); | 75 o.add(buildAttachment()); |
76 o.add(buildAttachment()); | 76 o.add(buildAttachment()); |
77 return o; | 77 return o; |
78 } | 78 } |
79 | 79 |
80 checkUnnamed670(core.List<api.Attachment> o) { | 80 checkUnnamed691(core.List<api.Attachment> o) { |
81 unittest.expect(o, unittest.hasLength(2)); | 81 unittest.expect(o, unittest.hasLength(2)); |
82 checkAttachment(o[0]); | 82 checkAttachment(o[0]); |
83 checkAttachment(o[1]); | 83 checkAttachment(o[1]); |
84 } | 84 } |
85 | 85 |
86 core.int buildCounterAssignmentSubmission = 0; | 86 core.int buildCounterAssignmentSubmission = 0; |
87 buildAssignmentSubmission() { | 87 buildAssignmentSubmission() { |
88 var o = new api.AssignmentSubmission(); | 88 var o = new api.AssignmentSubmission(); |
89 buildCounterAssignmentSubmission++; | 89 buildCounterAssignmentSubmission++; |
90 if (buildCounterAssignmentSubmission < 3) { | 90 if (buildCounterAssignmentSubmission < 3) { |
91 o.attachments = buildUnnamed670(); | 91 o.attachments = buildUnnamed691(); |
92 } | 92 } |
93 buildCounterAssignmentSubmission--; | 93 buildCounterAssignmentSubmission--; |
94 return o; | 94 return o; |
95 } | 95 } |
96 | 96 |
97 checkAssignmentSubmission(api.AssignmentSubmission o) { | 97 checkAssignmentSubmission(api.AssignmentSubmission o) { |
98 buildCounterAssignmentSubmission++; | 98 buildCounterAssignmentSubmission++; |
99 if (buildCounterAssignmentSubmission < 3) { | 99 if (buildCounterAssignmentSubmission < 3) { |
100 checkUnnamed670(o.attachments); | 100 checkUnnamed691(o.attachments); |
101 } | 101 } |
102 buildCounterAssignmentSubmission--; | 102 buildCounterAssignmentSubmission--; |
103 } | 103 } |
104 | 104 |
105 core.int buildCounterAttachment = 0; | 105 core.int buildCounterAttachment = 0; |
106 buildAttachment() { | 106 buildAttachment() { |
107 var o = new api.Attachment(); | 107 var o = new api.Attachment(); |
108 buildCounterAttachment++; | 108 buildCounterAttachment++; |
109 if (buildCounterAttachment < 3) { | 109 if (buildCounterAttachment < 3) { |
110 o.driveFile = buildDriveFile(); | 110 o.driveFile = buildDriveFile(); |
111 o.form = buildForm(); | 111 o.form = buildForm(); |
112 o.link = buildLink(); | 112 o.link = buildLink(); |
113 o.youTubeVideo = buildYouTubeVideo(); | 113 o.youTubeVideo = buildYouTubeVideo(); |
114 } | 114 } |
115 buildCounterAttachment--; | 115 buildCounterAttachment--; |
116 return o; | 116 return o; |
117 } | 117 } |
118 | 118 |
119 checkAttachment(api.Attachment o) { | 119 checkAttachment(api.Attachment o) { |
120 buildCounterAttachment++; | 120 buildCounterAttachment++; |
121 if (buildCounterAttachment < 3) { | 121 if (buildCounterAttachment < 3) { |
122 checkDriveFile(o.driveFile); | 122 checkDriveFile(o.driveFile); |
123 checkForm(o.form); | 123 checkForm(o.form); |
124 checkLink(o.link); | 124 checkLink(o.link); |
125 checkYouTubeVideo(o.youTubeVideo); | 125 checkYouTubeVideo(o.youTubeVideo); |
126 } | 126 } |
127 buildCounterAttachment--; | 127 buildCounterAttachment--; |
128 } | 128 } |
129 | 129 |
130 buildUnnamed671() { | 130 buildUnnamed692() { |
131 var o = new core.List<api.CourseMaterialSet>(); | 131 var o = new core.List<api.CourseMaterialSet>(); |
132 o.add(buildCourseMaterialSet()); | 132 o.add(buildCourseMaterialSet()); |
133 o.add(buildCourseMaterialSet()); | 133 o.add(buildCourseMaterialSet()); |
134 return o; | 134 return o; |
135 } | 135 } |
136 | 136 |
137 checkUnnamed671(core.List<api.CourseMaterialSet> o) { | 137 checkUnnamed692(core.List<api.CourseMaterialSet> o) { |
138 unittest.expect(o, unittest.hasLength(2)); | 138 unittest.expect(o, unittest.hasLength(2)); |
139 checkCourseMaterialSet(o[0]); | 139 checkCourseMaterialSet(o[0]); |
140 checkCourseMaterialSet(o[1]); | 140 checkCourseMaterialSet(o[1]); |
141 } | 141 } |
142 | 142 |
143 core.int buildCounterCourse = 0; | 143 core.int buildCounterCourse = 0; |
144 buildCourse() { | 144 buildCourse() { |
145 var o = new api.Course(); | 145 var o = new api.Course(); |
146 buildCounterCourse++; | 146 buildCounterCourse++; |
147 if (buildCounterCourse < 3) { | 147 if (buildCounterCourse < 3) { |
148 o.alternateLink = "foo"; | 148 o.alternateLink = "foo"; |
149 o.courseGroupEmail = "foo"; | 149 o.courseGroupEmail = "foo"; |
150 o.courseMaterialSets = buildUnnamed671(); | 150 o.courseMaterialSets = buildUnnamed692(); |
151 o.courseState = "foo"; | 151 o.courseState = "foo"; |
152 o.creationTime = "foo"; | 152 o.creationTime = "foo"; |
153 o.description = "foo"; | 153 o.description = "foo"; |
154 o.descriptionHeading = "foo"; | 154 o.descriptionHeading = "foo"; |
155 o.enrollmentCode = "foo"; | 155 o.enrollmentCode = "foo"; |
156 o.guardiansEnabled = true; | 156 o.guardiansEnabled = true; |
157 o.id = "foo"; | 157 o.id = "foo"; |
158 o.name = "foo"; | 158 o.name = "foo"; |
159 o.ownerId = "foo"; | 159 o.ownerId = "foo"; |
160 o.room = "foo"; | 160 o.room = "foo"; |
161 o.section = "foo"; | 161 o.section = "foo"; |
162 o.teacherFolder = buildDriveFolder(); | 162 o.teacherFolder = buildDriveFolder(); |
163 o.teacherGroupEmail = "foo"; | 163 o.teacherGroupEmail = "foo"; |
164 o.updateTime = "foo"; | 164 o.updateTime = "foo"; |
165 } | 165 } |
166 buildCounterCourse--; | 166 buildCounterCourse--; |
167 return o; | 167 return o; |
168 } | 168 } |
169 | 169 |
170 checkCourse(api.Course o) { | 170 checkCourse(api.Course o) { |
171 buildCounterCourse++; | 171 buildCounterCourse++; |
172 if (buildCounterCourse < 3) { | 172 if (buildCounterCourse < 3) { |
173 unittest.expect(o.alternateLink, unittest.equals('foo')); | 173 unittest.expect(o.alternateLink, unittest.equals('foo')); |
174 unittest.expect(o.courseGroupEmail, unittest.equals('foo')); | 174 unittest.expect(o.courseGroupEmail, unittest.equals('foo')); |
175 checkUnnamed671(o.courseMaterialSets); | 175 checkUnnamed692(o.courseMaterialSets); |
176 unittest.expect(o.courseState, unittest.equals('foo')); | 176 unittest.expect(o.courseState, unittest.equals('foo')); |
177 unittest.expect(o.creationTime, unittest.equals('foo')); | 177 unittest.expect(o.creationTime, unittest.equals('foo')); |
178 unittest.expect(o.description, unittest.equals('foo')); | 178 unittest.expect(o.description, unittest.equals('foo')); |
179 unittest.expect(o.descriptionHeading, unittest.equals('foo')); | 179 unittest.expect(o.descriptionHeading, unittest.equals('foo')); |
180 unittest.expect(o.enrollmentCode, unittest.equals('foo')); | 180 unittest.expect(o.enrollmentCode, unittest.equals('foo')); |
181 unittest.expect(o.guardiansEnabled, unittest.isTrue); | 181 unittest.expect(o.guardiansEnabled, unittest.isTrue); |
182 unittest.expect(o.id, unittest.equals('foo')); | 182 unittest.expect(o.id, unittest.equals('foo')); |
183 unittest.expect(o.name, unittest.equals('foo')); | 183 unittest.expect(o.name, unittest.equals('foo')); |
184 unittest.expect(o.ownerId, unittest.equals('foo')); | 184 unittest.expect(o.ownerId, unittest.equals('foo')); |
185 unittest.expect(o.room, unittest.equals('foo')); | 185 unittest.expect(o.room, unittest.equals('foo')); |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
228 buildCounterCourseMaterial++; | 228 buildCounterCourseMaterial++; |
229 if (buildCounterCourseMaterial < 3) { | 229 if (buildCounterCourseMaterial < 3) { |
230 checkDriveFile(o.driveFile); | 230 checkDriveFile(o.driveFile); |
231 checkForm(o.form); | 231 checkForm(o.form); |
232 checkLink(o.link); | 232 checkLink(o.link); |
233 checkYouTubeVideo(o.youTubeVideo); | 233 checkYouTubeVideo(o.youTubeVideo); |
234 } | 234 } |
235 buildCounterCourseMaterial--; | 235 buildCounterCourseMaterial--; |
236 } | 236 } |
237 | 237 |
238 buildUnnamed672() { | 238 buildUnnamed693() { |
239 var o = new core.List<api.CourseMaterial>(); | 239 var o = new core.List<api.CourseMaterial>(); |
240 o.add(buildCourseMaterial()); | 240 o.add(buildCourseMaterial()); |
241 o.add(buildCourseMaterial()); | 241 o.add(buildCourseMaterial()); |
242 return o; | 242 return o; |
243 } | 243 } |
244 | 244 |
245 checkUnnamed672(core.List<api.CourseMaterial> o) { | 245 checkUnnamed693(core.List<api.CourseMaterial> o) { |
246 unittest.expect(o, unittest.hasLength(2)); | 246 unittest.expect(o, unittest.hasLength(2)); |
247 checkCourseMaterial(o[0]); | 247 checkCourseMaterial(o[0]); |
248 checkCourseMaterial(o[1]); | 248 checkCourseMaterial(o[1]); |
249 } | 249 } |
250 | 250 |
251 core.int buildCounterCourseMaterialSet = 0; | 251 core.int buildCounterCourseMaterialSet = 0; |
252 buildCourseMaterialSet() { | 252 buildCourseMaterialSet() { |
253 var o = new api.CourseMaterialSet(); | 253 var o = new api.CourseMaterialSet(); |
254 buildCounterCourseMaterialSet++; | 254 buildCounterCourseMaterialSet++; |
255 if (buildCounterCourseMaterialSet < 3) { | 255 if (buildCounterCourseMaterialSet < 3) { |
256 o.materials = buildUnnamed672(); | 256 o.materials = buildUnnamed693(); |
257 o.title = "foo"; | 257 o.title = "foo"; |
258 } | 258 } |
259 buildCounterCourseMaterialSet--; | 259 buildCounterCourseMaterialSet--; |
260 return o; | 260 return o; |
261 } | 261 } |
262 | 262 |
263 checkCourseMaterialSet(api.CourseMaterialSet o) { | 263 checkCourseMaterialSet(api.CourseMaterialSet o) { |
264 buildCounterCourseMaterialSet++; | 264 buildCounterCourseMaterialSet++; |
265 if (buildCounterCourseMaterialSet < 3) { | 265 if (buildCounterCourseMaterialSet < 3) { |
266 checkUnnamed672(o.materials); | 266 checkUnnamed693(o.materials); |
267 unittest.expect(o.title, unittest.equals('foo')); | 267 unittest.expect(o.title, unittest.equals('foo')); |
268 } | 268 } |
269 buildCounterCourseMaterialSet--; | 269 buildCounterCourseMaterialSet--; |
270 } | 270 } |
271 | 271 |
272 buildUnnamed673() { | 272 buildUnnamed694() { |
273 var o = new core.List<api.Material>(); | 273 var o = new core.List<api.Material>(); |
274 o.add(buildMaterial()); | 274 o.add(buildMaterial()); |
275 o.add(buildMaterial()); | 275 o.add(buildMaterial()); |
276 return o; | 276 return o; |
277 } | 277 } |
278 | 278 |
279 checkUnnamed673(core.List<api.Material> o) { | 279 checkUnnamed694(core.List<api.Material> o) { |
280 unittest.expect(o, unittest.hasLength(2)); | 280 unittest.expect(o, unittest.hasLength(2)); |
281 checkMaterial(o[0]); | 281 checkMaterial(o[0]); |
282 checkMaterial(o[1]); | 282 checkMaterial(o[1]); |
283 } | 283 } |
284 | 284 |
285 core.int buildCounterCourseWork = 0; | 285 core.int buildCounterCourseWork = 0; |
286 buildCourseWork() { | 286 buildCourseWork() { |
287 var o = new api.CourseWork(); | 287 var o = new api.CourseWork(); |
288 buildCounterCourseWork++; | 288 buildCounterCourseWork++; |
289 if (buildCounterCourseWork < 3) { | 289 if (buildCounterCourseWork < 3) { |
290 o.alternateLink = "foo"; | 290 o.alternateLink = "foo"; |
291 o.assignment = buildAssignment(); | 291 o.assignment = buildAssignment(); |
292 o.associatedWithDeveloper = true; | 292 o.associatedWithDeveloper = true; |
293 o.courseId = "foo"; | 293 o.courseId = "foo"; |
294 o.creationTime = "foo"; | 294 o.creationTime = "foo"; |
295 o.description = "foo"; | 295 o.description = "foo"; |
296 o.dueDate = buildDate(); | 296 o.dueDate = buildDate(); |
297 o.dueTime = buildTimeOfDay(); | 297 o.dueTime = buildTimeOfDay(); |
298 o.id = "foo"; | 298 o.id = "foo"; |
299 o.materials = buildUnnamed673(); | 299 o.materials = buildUnnamed694(); |
300 o.maxPoints = 42.0; | 300 o.maxPoints = 42.0; |
301 o.multipleChoiceQuestion = buildMultipleChoiceQuestion(); | 301 o.multipleChoiceQuestion = buildMultipleChoiceQuestion(); |
302 o.state = "foo"; | 302 o.state = "foo"; |
303 o.submissionModificationMode = "foo"; | 303 o.submissionModificationMode = "foo"; |
304 o.title = "foo"; | 304 o.title = "foo"; |
305 o.updateTime = "foo"; | 305 o.updateTime = "foo"; |
306 o.workType = "foo"; | 306 o.workType = "foo"; |
307 } | 307 } |
308 buildCounterCourseWork--; | 308 buildCounterCourseWork--; |
309 return o; | 309 return o; |
310 } | 310 } |
311 | 311 |
312 checkCourseWork(api.CourseWork o) { | 312 checkCourseWork(api.CourseWork o) { |
313 buildCounterCourseWork++; | 313 buildCounterCourseWork++; |
314 if (buildCounterCourseWork < 3) { | 314 if (buildCounterCourseWork < 3) { |
315 unittest.expect(o.alternateLink, unittest.equals('foo')); | 315 unittest.expect(o.alternateLink, unittest.equals('foo')); |
316 checkAssignment(o.assignment); | 316 checkAssignment(o.assignment); |
317 unittest.expect(o.associatedWithDeveloper, unittest.isTrue); | 317 unittest.expect(o.associatedWithDeveloper, unittest.isTrue); |
318 unittest.expect(o.courseId, unittest.equals('foo')); | 318 unittest.expect(o.courseId, unittest.equals('foo')); |
319 unittest.expect(o.creationTime, unittest.equals('foo')); | 319 unittest.expect(o.creationTime, unittest.equals('foo')); |
320 unittest.expect(o.description, unittest.equals('foo')); | 320 unittest.expect(o.description, unittest.equals('foo')); |
321 checkDate(o.dueDate); | 321 checkDate(o.dueDate); |
322 checkTimeOfDay(o.dueTime); | 322 checkTimeOfDay(o.dueTime); |
323 unittest.expect(o.id, unittest.equals('foo')); | 323 unittest.expect(o.id, unittest.equals('foo')); |
324 checkUnnamed673(o.materials); | 324 checkUnnamed694(o.materials); |
325 unittest.expect(o.maxPoints, unittest.equals(42.0)); | 325 unittest.expect(o.maxPoints, unittest.equals(42.0)); |
326 checkMultipleChoiceQuestion(o.multipleChoiceQuestion); | 326 checkMultipleChoiceQuestion(o.multipleChoiceQuestion); |
327 unittest.expect(o.state, unittest.equals('foo')); | 327 unittest.expect(o.state, unittest.equals('foo')); |
328 unittest.expect(o.submissionModificationMode, unittest.equals('foo')); | 328 unittest.expect(o.submissionModificationMode, unittest.equals('foo')); |
329 unittest.expect(o.title, unittest.equals('foo')); | 329 unittest.expect(o.title, unittest.equals('foo')); |
330 unittest.expect(o.updateTime, unittest.equals('foo')); | 330 unittest.expect(o.updateTime, unittest.equals('foo')); |
331 unittest.expect(o.workType, unittest.equals('foo')); | 331 unittest.expect(o.workType, unittest.equals('foo')); |
332 } | 332 } |
333 buildCounterCourseWork--; | 333 buildCounterCourseWork--; |
334 } | 334 } |
(...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
558 checkLink(api.Link o) { | 558 checkLink(api.Link o) { |
559 buildCounterLink++; | 559 buildCounterLink++; |
560 if (buildCounterLink < 3) { | 560 if (buildCounterLink < 3) { |
561 unittest.expect(o.thumbnailUrl, unittest.equals('foo')); | 561 unittest.expect(o.thumbnailUrl, unittest.equals('foo')); |
562 unittest.expect(o.title, unittest.equals('foo')); | 562 unittest.expect(o.title, unittest.equals('foo')); |
563 unittest.expect(o.url, unittest.equals('foo')); | 563 unittest.expect(o.url, unittest.equals('foo')); |
564 } | 564 } |
565 buildCounterLink--; | 565 buildCounterLink--; |
566 } | 566 } |
567 | 567 |
568 buildUnnamed674() { | 568 buildUnnamed695() { |
569 var o = new core.List<api.CourseAlias>(); | 569 var o = new core.List<api.CourseAlias>(); |
570 o.add(buildCourseAlias()); | 570 o.add(buildCourseAlias()); |
571 o.add(buildCourseAlias()); | 571 o.add(buildCourseAlias()); |
572 return o; | 572 return o; |
573 } | 573 } |
574 | 574 |
575 checkUnnamed674(core.List<api.CourseAlias> o) { | 575 checkUnnamed695(core.List<api.CourseAlias> o) { |
576 unittest.expect(o, unittest.hasLength(2)); | 576 unittest.expect(o, unittest.hasLength(2)); |
577 checkCourseAlias(o[0]); | 577 checkCourseAlias(o[0]); |
578 checkCourseAlias(o[1]); | 578 checkCourseAlias(o[1]); |
579 } | 579 } |
580 | 580 |
581 core.int buildCounterListCourseAliasesResponse = 0; | 581 core.int buildCounterListCourseAliasesResponse = 0; |
582 buildListCourseAliasesResponse() { | 582 buildListCourseAliasesResponse() { |
583 var o = new api.ListCourseAliasesResponse(); | 583 var o = new api.ListCourseAliasesResponse(); |
584 buildCounterListCourseAliasesResponse++; | 584 buildCounterListCourseAliasesResponse++; |
585 if (buildCounterListCourseAliasesResponse < 3) { | 585 if (buildCounterListCourseAliasesResponse < 3) { |
586 o.aliases = buildUnnamed674(); | 586 o.aliases = buildUnnamed695(); |
587 o.nextPageToken = "foo"; | 587 o.nextPageToken = "foo"; |
588 } | 588 } |
589 buildCounterListCourseAliasesResponse--; | 589 buildCounterListCourseAliasesResponse--; |
590 return o; | 590 return o; |
591 } | 591 } |
592 | 592 |
593 checkListCourseAliasesResponse(api.ListCourseAliasesResponse o) { | 593 checkListCourseAliasesResponse(api.ListCourseAliasesResponse o) { |
594 buildCounterListCourseAliasesResponse++; | 594 buildCounterListCourseAliasesResponse++; |
595 if (buildCounterListCourseAliasesResponse < 3) { | 595 if (buildCounterListCourseAliasesResponse < 3) { |
596 checkUnnamed674(o.aliases); | 596 checkUnnamed695(o.aliases); |
597 unittest.expect(o.nextPageToken, unittest.equals('foo')); | 597 unittest.expect(o.nextPageToken, unittest.equals('foo')); |
598 } | 598 } |
599 buildCounterListCourseAliasesResponse--; | 599 buildCounterListCourseAliasesResponse--; |
600 } | 600 } |
601 | 601 |
602 buildUnnamed675() { | 602 buildUnnamed696() { |
603 var o = new core.List<api.CourseWork>(); | 603 var o = new core.List<api.CourseWork>(); |
604 o.add(buildCourseWork()); | 604 o.add(buildCourseWork()); |
605 o.add(buildCourseWork()); | 605 o.add(buildCourseWork()); |
606 return o; | 606 return o; |
607 } | 607 } |
608 | 608 |
609 checkUnnamed675(core.List<api.CourseWork> o) { | 609 checkUnnamed696(core.List<api.CourseWork> o) { |
610 unittest.expect(o, unittest.hasLength(2)); | 610 unittest.expect(o, unittest.hasLength(2)); |
611 checkCourseWork(o[0]); | 611 checkCourseWork(o[0]); |
612 checkCourseWork(o[1]); | 612 checkCourseWork(o[1]); |
613 } | 613 } |
614 | 614 |
615 core.int buildCounterListCourseWorkResponse = 0; | 615 core.int buildCounterListCourseWorkResponse = 0; |
616 buildListCourseWorkResponse() { | 616 buildListCourseWorkResponse() { |
617 var o = new api.ListCourseWorkResponse(); | 617 var o = new api.ListCourseWorkResponse(); |
618 buildCounterListCourseWorkResponse++; | 618 buildCounterListCourseWorkResponse++; |
619 if (buildCounterListCourseWorkResponse < 3) { | 619 if (buildCounterListCourseWorkResponse < 3) { |
620 o.courseWork = buildUnnamed675(); | 620 o.courseWork = buildUnnamed696(); |
621 o.nextPageToken = "foo"; | 621 o.nextPageToken = "foo"; |
622 } | 622 } |
623 buildCounterListCourseWorkResponse--; | 623 buildCounterListCourseWorkResponse--; |
624 return o; | 624 return o; |
625 } | 625 } |
626 | 626 |
627 checkListCourseWorkResponse(api.ListCourseWorkResponse o) { | 627 checkListCourseWorkResponse(api.ListCourseWorkResponse o) { |
628 buildCounterListCourseWorkResponse++; | 628 buildCounterListCourseWorkResponse++; |
629 if (buildCounterListCourseWorkResponse < 3) { | 629 if (buildCounterListCourseWorkResponse < 3) { |
630 checkUnnamed675(o.courseWork); | 630 checkUnnamed696(o.courseWork); |
631 unittest.expect(o.nextPageToken, unittest.equals('foo')); | 631 unittest.expect(o.nextPageToken, unittest.equals('foo')); |
632 } | 632 } |
633 buildCounterListCourseWorkResponse--; | 633 buildCounterListCourseWorkResponse--; |
634 } | 634 } |
635 | 635 |
636 buildUnnamed676() { | 636 buildUnnamed697() { |
637 var o = new core.List<api.Course>(); | 637 var o = new core.List<api.Course>(); |
638 o.add(buildCourse()); | 638 o.add(buildCourse()); |
639 o.add(buildCourse()); | 639 o.add(buildCourse()); |
640 return o; | 640 return o; |
641 } | 641 } |
642 | 642 |
643 checkUnnamed676(core.List<api.Course> o) { | 643 checkUnnamed697(core.List<api.Course> o) { |
644 unittest.expect(o, unittest.hasLength(2)); | 644 unittest.expect(o, unittest.hasLength(2)); |
645 checkCourse(o[0]); | 645 checkCourse(o[0]); |
646 checkCourse(o[1]); | 646 checkCourse(o[1]); |
647 } | 647 } |
648 | 648 |
649 core.int buildCounterListCoursesResponse = 0; | 649 core.int buildCounterListCoursesResponse = 0; |
650 buildListCoursesResponse() { | 650 buildListCoursesResponse() { |
651 var o = new api.ListCoursesResponse(); | 651 var o = new api.ListCoursesResponse(); |
652 buildCounterListCoursesResponse++; | 652 buildCounterListCoursesResponse++; |
653 if (buildCounterListCoursesResponse < 3) { | 653 if (buildCounterListCoursesResponse < 3) { |
654 o.courses = buildUnnamed676(); | 654 o.courses = buildUnnamed697(); |
655 o.nextPageToken = "foo"; | 655 o.nextPageToken = "foo"; |
656 } | 656 } |
657 buildCounterListCoursesResponse--; | 657 buildCounterListCoursesResponse--; |
658 return o; | 658 return o; |
659 } | 659 } |
660 | 660 |
661 checkListCoursesResponse(api.ListCoursesResponse o) { | 661 checkListCoursesResponse(api.ListCoursesResponse o) { |
662 buildCounterListCoursesResponse++; | 662 buildCounterListCoursesResponse++; |
663 if (buildCounterListCoursesResponse < 3) { | 663 if (buildCounterListCoursesResponse < 3) { |
664 checkUnnamed676(o.courses); | 664 checkUnnamed697(o.courses); |
665 unittest.expect(o.nextPageToken, unittest.equals('foo')); | 665 unittest.expect(o.nextPageToken, unittest.equals('foo')); |
666 } | 666 } |
667 buildCounterListCoursesResponse--; | 667 buildCounterListCoursesResponse--; |
668 } | 668 } |
669 | 669 |
670 buildUnnamed677() { | 670 buildUnnamed698() { |
671 var o = new core.List<api.GuardianInvitation>(); | 671 var o = new core.List<api.GuardianInvitation>(); |
672 o.add(buildGuardianInvitation()); | 672 o.add(buildGuardianInvitation()); |
673 o.add(buildGuardianInvitation()); | 673 o.add(buildGuardianInvitation()); |
674 return o; | 674 return o; |
675 } | 675 } |
676 | 676 |
677 checkUnnamed677(core.List<api.GuardianInvitation> o) { | 677 checkUnnamed698(core.List<api.GuardianInvitation> o) { |
678 unittest.expect(o, unittest.hasLength(2)); | 678 unittest.expect(o, unittest.hasLength(2)); |
679 checkGuardianInvitation(o[0]); | 679 checkGuardianInvitation(o[0]); |
680 checkGuardianInvitation(o[1]); | 680 checkGuardianInvitation(o[1]); |
681 } | 681 } |
682 | 682 |
683 core.int buildCounterListGuardianInvitationsResponse = 0; | 683 core.int buildCounterListGuardianInvitationsResponse = 0; |
684 buildListGuardianInvitationsResponse() { | 684 buildListGuardianInvitationsResponse() { |
685 var o = new api.ListGuardianInvitationsResponse(); | 685 var o = new api.ListGuardianInvitationsResponse(); |
686 buildCounterListGuardianInvitationsResponse++; | 686 buildCounterListGuardianInvitationsResponse++; |
687 if (buildCounterListGuardianInvitationsResponse < 3) { | 687 if (buildCounterListGuardianInvitationsResponse < 3) { |
688 o.guardianInvitations = buildUnnamed677(); | 688 o.guardianInvitations = buildUnnamed698(); |
689 o.nextPageToken = "foo"; | 689 o.nextPageToken = "foo"; |
690 } | 690 } |
691 buildCounterListGuardianInvitationsResponse--; | 691 buildCounterListGuardianInvitationsResponse--; |
692 return o; | 692 return o; |
693 } | 693 } |
694 | 694 |
695 checkListGuardianInvitationsResponse(api.ListGuardianInvitationsResponse o) { | 695 checkListGuardianInvitationsResponse(api.ListGuardianInvitationsResponse o) { |
696 buildCounterListGuardianInvitationsResponse++; | 696 buildCounterListGuardianInvitationsResponse++; |
697 if (buildCounterListGuardianInvitationsResponse < 3) { | 697 if (buildCounterListGuardianInvitationsResponse < 3) { |
698 checkUnnamed677(o.guardianInvitations); | 698 checkUnnamed698(o.guardianInvitations); |
699 unittest.expect(o.nextPageToken, unittest.equals('foo')); | 699 unittest.expect(o.nextPageToken, unittest.equals('foo')); |
700 } | 700 } |
701 buildCounterListGuardianInvitationsResponse--; | 701 buildCounterListGuardianInvitationsResponse--; |
702 } | 702 } |
703 | 703 |
704 buildUnnamed678() { | 704 buildUnnamed699() { |
705 var o = new core.List<api.Guardian>(); | 705 var o = new core.List<api.Guardian>(); |
706 o.add(buildGuardian()); | 706 o.add(buildGuardian()); |
707 o.add(buildGuardian()); | 707 o.add(buildGuardian()); |
708 return o; | 708 return o; |
709 } | 709 } |
710 | 710 |
711 checkUnnamed678(core.List<api.Guardian> o) { | 711 checkUnnamed699(core.List<api.Guardian> o) { |
712 unittest.expect(o, unittest.hasLength(2)); | 712 unittest.expect(o, unittest.hasLength(2)); |
713 checkGuardian(o[0]); | 713 checkGuardian(o[0]); |
714 checkGuardian(o[1]); | 714 checkGuardian(o[1]); |
715 } | 715 } |
716 | 716 |
717 core.int buildCounterListGuardiansResponse = 0; | 717 core.int buildCounterListGuardiansResponse = 0; |
718 buildListGuardiansResponse() { | 718 buildListGuardiansResponse() { |
719 var o = new api.ListGuardiansResponse(); | 719 var o = new api.ListGuardiansResponse(); |
720 buildCounterListGuardiansResponse++; | 720 buildCounterListGuardiansResponse++; |
721 if (buildCounterListGuardiansResponse < 3) { | 721 if (buildCounterListGuardiansResponse < 3) { |
722 o.guardians = buildUnnamed678(); | 722 o.guardians = buildUnnamed699(); |
723 o.nextPageToken = "foo"; | 723 o.nextPageToken = "foo"; |
724 } | 724 } |
725 buildCounterListGuardiansResponse--; | 725 buildCounterListGuardiansResponse--; |
726 return o; | 726 return o; |
727 } | 727 } |
728 | 728 |
729 checkListGuardiansResponse(api.ListGuardiansResponse o) { | 729 checkListGuardiansResponse(api.ListGuardiansResponse o) { |
730 buildCounterListGuardiansResponse++; | 730 buildCounterListGuardiansResponse++; |
731 if (buildCounterListGuardiansResponse < 3) { | 731 if (buildCounterListGuardiansResponse < 3) { |
732 checkUnnamed678(o.guardians); | 732 checkUnnamed699(o.guardians); |
733 unittest.expect(o.nextPageToken, unittest.equals('foo')); | 733 unittest.expect(o.nextPageToken, unittest.equals('foo')); |
734 } | 734 } |
735 buildCounterListGuardiansResponse--; | 735 buildCounterListGuardiansResponse--; |
736 } | 736 } |
737 | 737 |
738 buildUnnamed679() { | 738 buildUnnamed700() { |
739 var o = new core.List<api.Invitation>(); | 739 var o = new core.List<api.Invitation>(); |
740 o.add(buildInvitation()); | 740 o.add(buildInvitation()); |
741 o.add(buildInvitation()); | 741 o.add(buildInvitation()); |
742 return o; | 742 return o; |
743 } | 743 } |
744 | 744 |
745 checkUnnamed679(core.List<api.Invitation> o) { | 745 checkUnnamed700(core.List<api.Invitation> o) { |
746 unittest.expect(o, unittest.hasLength(2)); | 746 unittest.expect(o, unittest.hasLength(2)); |
747 checkInvitation(o[0]); | 747 checkInvitation(o[0]); |
748 checkInvitation(o[1]); | 748 checkInvitation(o[1]); |
749 } | 749 } |
750 | 750 |
751 core.int buildCounterListInvitationsResponse = 0; | 751 core.int buildCounterListInvitationsResponse = 0; |
752 buildListInvitationsResponse() { | 752 buildListInvitationsResponse() { |
753 var o = new api.ListInvitationsResponse(); | 753 var o = new api.ListInvitationsResponse(); |
754 buildCounterListInvitationsResponse++; | 754 buildCounterListInvitationsResponse++; |
755 if (buildCounterListInvitationsResponse < 3) { | 755 if (buildCounterListInvitationsResponse < 3) { |
756 o.invitations = buildUnnamed679(); | 756 o.invitations = buildUnnamed700(); |
757 o.nextPageToken = "foo"; | 757 o.nextPageToken = "foo"; |
758 } | 758 } |
759 buildCounterListInvitationsResponse--; | 759 buildCounterListInvitationsResponse--; |
760 return o; | 760 return o; |
761 } | 761 } |
762 | 762 |
763 checkListInvitationsResponse(api.ListInvitationsResponse o) { | 763 checkListInvitationsResponse(api.ListInvitationsResponse o) { |
764 buildCounterListInvitationsResponse++; | 764 buildCounterListInvitationsResponse++; |
765 if (buildCounterListInvitationsResponse < 3) { | 765 if (buildCounterListInvitationsResponse < 3) { |
766 checkUnnamed679(o.invitations); | 766 checkUnnamed700(o.invitations); |
767 unittest.expect(o.nextPageToken, unittest.equals('foo')); | 767 unittest.expect(o.nextPageToken, unittest.equals('foo')); |
768 } | 768 } |
769 buildCounterListInvitationsResponse--; | 769 buildCounterListInvitationsResponse--; |
770 } | 770 } |
771 | 771 |
772 buildUnnamed680() { | 772 buildUnnamed701() { |
773 var o = new core.List<api.StudentSubmission>(); | 773 var o = new core.List<api.StudentSubmission>(); |
774 o.add(buildStudentSubmission()); | 774 o.add(buildStudentSubmission()); |
775 o.add(buildStudentSubmission()); | 775 o.add(buildStudentSubmission()); |
776 return o; | 776 return o; |
777 } | 777 } |
778 | 778 |
779 checkUnnamed680(core.List<api.StudentSubmission> o) { | 779 checkUnnamed701(core.List<api.StudentSubmission> o) { |
780 unittest.expect(o, unittest.hasLength(2)); | 780 unittest.expect(o, unittest.hasLength(2)); |
781 checkStudentSubmission(o[0]); | 781 checkStudentSubmission(o[0]); |
782 checkStudentSubmission(o[1]); | 782 checkStudentSubmission(o[1]); |
783 } | 783 } |
784 | 784 |
785 core.int buildCounterListStudentSubmissionsResponse = 0; | 785 core.int buildCounterListStudentSubmissionsResponse = 0; |
786 buildListStudentSubmissionsResponse() { | 786 buildListStudentSubmissionsResponse() { |
787 var o = new api.ListStudentSubmissionsResponse(); | 787 var o = new api.ListStudentSubmissionsResponse(); |
788 buildCounterListStudentSubmissionsResponse++; | 788 buildCounterListStudentSubmissionsResponse++; |
789 if (buildCounterListStudentSubmissionsResponse < 3) { | 789 if (buildCounterListStudentSubmissionsResponse < 3) { |
790 o.nextPageToken = "foo"; | 790 o.nextPageToken = "foo"; |
791 o.studentSubmissions = buildUnnamed680(); | 791 o.studentSubmissions = buildUnnamed701(); |
792 } | 792 } |
793 buildCounterListStudentSubmissionsResponse--; | 793 buildCounterListStudentSubmissionsResponse--; |
794 return o; | 794 return o; |
795 } | 795 } |
796 | 796 |
797 checkListStudentSubmissionsResponse(api.ListStudentSubmissionsResponse o) { | 797 checkListStudentSubmissionsResponse(api.ListStudentSubmissionsResponse o) { |
798 buildCounterListStudentSubmissionsResponse++; | 798 buildCounterListStudentSubmissionsResponse++; |
799 if (buildCounterListStudentSubmissionsResponse < 3) { | 799 if (buildCounterListStudentSubmissionsResponse < 3) { |
800 unittest.expect(o.nextPageToken, unittest.equals('foo')); | 800 unittest.expect(o.nextPageToken, unittest.equals('foo')); |
801 checkUnnamed680(o.studentSubmissions); | 801 checkUnnamed701(o.studentSubmissions); |
802 } | 802 } |
803 buildCounterListStudentSubmissionsResponse--; | 803 buildCounterListStudentSubmissionsResponse--; |
804 } | 804 } |
805 | 805 |
806 buildUnnamed681() { | 806 buildUnnamed702() { |
807 var o = new core.List<api.Student>(); | 807 var o = new core.List<api.Student>(); |
808 o.add(buildStudent()); | 808 o.add(buildStudent()); |
809 o.add(buildStudent()); | 809 o.add(buildStudent()); |
810 return o; | 810 return o; |
811 } | 811 } |
812 | 812 |
813 checkUnnamed681(core.List<api.Student> o) { | 813 checkUnnamed702(core.List<api.Student> o) { |
814 unittest.expect(o, unittest.hasLength(2)); | 814 unittest.expect(o, unittest.hasLength(2)); |
815 checkStudent(o[0]); | 815 checkStudent(o[0]); |
816 checkStudent(o[1]); | 816 checkStudent(o[1]); |
817 } | 817 } |
818 | 818 |
819 core.int buildCounterListStudentsResponse = 0; | 819 core.int buildCounterListStudentsResponse = 0; |
820 buildListStudentsResponse() { | 820 buildListStudentsResponse() { |
821 var o = new api.ListStudentsResponse(); | 821 var o = new api.ListStudentsResponse(); |
822 buildCounterListStudentsResponse++; | 822 buildCounterListStudentsResponse++; |
823 if (buildCounterListStudentsResponse < 3) { | 823 if (buildCounterListStudentsResponse < 3) { |
824 o.nextPageToken = "foo"; | 824 o.nextPageToken = "foo"; |
825 o.students = buildUnnamed681(); | 825 o.students = buildUnnamed702(); |
826 } | 826 } |
827 buildCounterListStudentsResponse--; | 827 buildCounterListStudentsResponse--; |
828 return o; | 828 return o; |
829 } | 829 } |
830 | 830 |
831 checkListStudentsResponse(api.ListStudentsResponse o) { | 831 checkListStudentsResponse(api.ListStudentsResponse o) { |
832 buildCounterListStudentsResponse++; | 832 buildCounterListStudentsResponse++; |
833 if (buildCounterListStudentsResponse < 3) { | 833 if (buildCounterListStudentsResponse < 3) { |
834 unittest.expect(o.nextPageToken, unittest.equals('foo')); | 834 unittest.expect(o.nextPageToken, unittest.equals('foo')); |
835 checkUnnamed681(o.students); | 835 checkUnnamed702(o.students); |
836 } | 836 } |
837 buildCounterListStudentsResponse--; | 837 buildCounterListStudentsResponse--; |
838 } | 838 } |
839 | 839 |
840 buildUnnamed682() { | 840 buildUnnamed703() { |
841 var o = new core.List<api.Teacher>(); | 841 var o = new core.List<api.Teacher>(); |
842 o.add(buildTeacher()); | 842 o.add(buildTeacher()); |
843 o.add(buildTeacher()); | 843 o.add(buildTeacher()); |
844 return o; | 844 return o; |
845 } | 845 } |
846 | 846 |
847 checkUnnamed682(core.List<api.Teacher> o) { | 847 checkUnnamed703(core.List<api.Teacher> o) { |
848 unittest.expect(o, unittest.hasLength(2)); | 848 unittest.expect(o, unittest.hasLength(2)); |
849 checkTeacher(o[0]); | 849 checkTeacher(o[0]); |
850 checkTeacher(o[1]); | 850 checkTeacher(o[1]); |
851 } | 851 } |
852 | 852 |
853 core.int buildCounterListTeachersResponse = 0; | 853 core.int buildCounterListTeachersResponse = 0; |
854 buildListTeachersResponse() { | 854 buildListTeachersResponse() { |
855 var o = new api.ListTeachersResponse(); | 855 var o = new api.ListTeachersResponse(); |
856 buildCounterListTeachersResponse++; | 856 buildCounterListTeachersResponse++; |
857 if (buildCounterListTeachersResponse < 3) { | 857 if (buildCounterListTeachersResponse < 3) { |
858 o.nextPageToken = "foo"; | 858 o.nextPageToken = "foo"; |
859 o.teachers = buildUnnamed682(); | 859 o.teachers = buildUnnamed703(); |
860 } | 860 } |
861 buildCounterListTeachersResponse--; | 861 buildCounterListTeachersResponse--; |
862 return o; | 862 return o; |
863 } | 863 } |
864 | 864 |
865 checkListTeachersResponse(api.ListTeachersResponse o) { | 865 checkListTeachersResponse(api.ListTeachersResponse o) { |
866 buildCounterListTeachersResponse++; | 866 buildCounterListTeachersResponse++; |
867 if (buildCounterListTeachersResponse < 3) { | 867 if (buildCounterListTeachersResponse < 3) { |
868 unittest.expect(o.nextPageToken, unittest.equals('foo')); | 868 unittest.expect(o.nextPageToken, unittest.equals('foo')); |
869 checkUnnamed682(o.teachers); | 869 checkUnnamed703(o.teachers); |
870 } | 870 } |
871 buildCounterListTeachersResponse--; | 871 buildCounterListTeachersResponse--; |
872 } | 872 } |
873 | 873 |
874 core.int buildCounterMaterial = 0; | 874 core.int buildCounterMaterial = 0; |
875 buildMaterial() { | 875 buildMaterial() { |
876 var o = new api.Material(); | 876 var o = new api.Material(); |
877 buildCounterMaterial++; | 877 buildCounterMaterial++; |
878 if (buildCounterMaterial < 3) { | 878 if (buildCounterMaterial < 3) { |
879 o.driveFile = buildSharedDriveFile(); | 879 o.driveFile = buildSharedDriveFile(); |
880 o.form = buildForm(); | 880 o.form = buildForm(); |
881 o.link = buildLink(); | 881 o.link = buildLink(); |
882 o.youtubeVideo = buildYouTubeVideo(); | 882 o.youtubeVideo = buildYouTubeVideo(); |
883 } | 883 } |
884 buildCounterMaterial--; | 884 buildCounterMaterial--; |
885 return o; | 885 return o; |
886 } | 886 } |
887 | 887 |
888 checkMaterial(api.Material o) { | 888 checkMaterial(api.Material o) { |
889 buildCounterMaterial++; | 889 buildCounterMaterial++; |
890 if (buildCounterMaterial < 3) { | 890 if (buildCounterMaterial < 3) { |
891 checkSharedDriveFile(o.driveFile); | 891 checkSharedDriveFile(o.driveFile); |
892 checkForm(o.form); | 892 checkForm(o.form); |
893 checkLink(o.link); | 893 checkLink(o.link); |
894 checkYouTubeVideo(o.youtubeVideo); | 894 checkYouTubeVideo(o.youtubeVideo); |
895 } | 895 } |
896 buildCounterMaterial--; | 896 buildCounterMaterial--; |
897 } | 897 } |
898 | 898 |
899 buildUnnamed683() { | 899 buildUnnamed704() { |
900 var o = new core.List<api.Attachment>(); | 900 var o = new core.List<api.Attachment>(); |
901 o.add(buildAttachment()); | 901 o.add(buildAttachment()); |
902 o.add(buildAttachment()); | 902 o.add(buildAttachment()); |
903 return o; | 903 return o; |
904 } | 904 } |
905 | 905 |
906 checkUnnamed683(core.List<api.Attachment> o) { | 906 checkUnnamed704(core.List<api.Attachment> o) { |
907 unittest.expect(o, unittest.hasLength(2)); | 907 unittest.expect(o, unittest.hasLength(2)); |
908 checkAttachment(o[0]); | 908 checkAttachment(o[0]); |
909 checkAttachment(o[1]); | 909 checkAttachment(o[1]); |
910 } | 910 } |
911 | 911 |
912 core.int buildCounterModifyAttachmentsRequest = 0; | 912 core.int buildCounterModifyAttachmentsRequest = 0; |
913 buildModifyAttachmentsRequest() { | 913 buildModifyAttachmentsRequest() { |
914 var o = new api.ModifyAttachmentsRequest(); | 914 var o = new api.ModifyAttachmentsRequest(); |
915 buildCounterModifyAttachmentsRequest++; | 915 buildCounterModifyAttachmentsRequest++; |
916 if (buildCounterModifyAttachmentsRequest < 3) { | 916 if (buildCounterModifyAttachmentsRequest < 3) { |
917 o.addAttachments = buildUnnamed683(); | 917 o.addAttachments = buildUnnamed704(); |
918 } | 918 } |
919 buildCounterModifyAttachmentsRequest--; | 919 buildCounterModifyAttachmentsRequest--; |
920 return o; | 920 return o; |
921 } | 921 } |
922 | 922 |
923 checkModifyAttachmentsRequest(api.ModifyAttachmentsRequest o) { | 923 checkModifyAttachmentsRequest(api.ModifyAttachmentsRequest o) { |
924 buildCounterModifyAttachmentsRequest++; | 924 buildCounterModifyAttachmentsRequest++; |
925 if (buildCounterModifyAttachmentsRequest < 3) { | 925 if (buildCounterModifyAttachmentsRequest < 3) { |
926 checkUnnamed683(o.addAttachments); | 926 checkUnnamed704(o.addAttachments); |
927 } | 927 } |
928 buildCounterModifyAttachmentsRequest--; | 928 buildCounterModifyAttachmentsRequest--; |
929 } | 929 } |
930 | 930 |
931 buildUnnamed684() { | 931 buildUnnamed705() { |
932 var o = new core.List<core.String>(); | 932 var o = new core.List<core.String>(); |
933 o.add("foo"); | 933 o.add("foo"); |
934 o.add("foo"); | 934 o.add("foo"); |
935 return o; | 935 return o; |
936 } | 936 } |
937 | 937 |
938 checkUnnamed684(core.List<core.String> o) { | 938 checkUnnamed705(core.List<core.String> o) { |
939 unittest.expect(o, unittest.hasLength(2)); | 939 unittest.expect(o, unittest.hasLength(2)); |
940 unittest.expect(o[0], unittest.equals('foo')); | 940 unittest.expect(o[0], unittest.equals('foo')); |
941 unittest.expect(o[1], unittest.equals('foo')); | 941 unittest.expect(o[1], unittest.equals('foo')); |
942 } | 942 } |
943 | 943 |
944 core.int buildCounterMultipleChoiceQuestion = 0; | 944 core.int buildCounterMultipleChoiceQuestion = 0; |
945 buildMultipleChoiceQuestion() { | 945 buildMultipleChoiceQuestion() { |
946 var o = new api.MultipleChoiceQuestion(); | 946 var o = new api.MultipleChoiceQuestion(); |
947 buildCounterMultipleChoiceQuestion++; | 947 buildCounterMultipleChoiceQuestion++; |
948 if (buildCounterMultipleChoiceQuestion < 3) { | 948 if (buildCounterMultipleChoiceQuestion < 3) { |
949 o.choices = buildUnnamed684(); | 949 o.choices = buildUnnamed705(); |
950 } | 950 } |
951 buildCounterMultipleChoiceQuestion--; | 951 buildCounterMultipleChoiceQuestion--; |
952 return o; | 952 return o; |
953 } | 953 } |
954 | 954 |
955 checkMultipleChoiceQuestion(api.MultipleChoiceQuestion o) { | 955 checkMultipleChoiceQuestion(api.MultipleChoiceQuestion o) { |
956 buildCounterMultipleChoiceQuestion++; | 956 buildCounterMultipleChoiceQuestion++; |
957 if (buildCounterMultipleChoiceQuestion < 3) { | 957 if (buildCounterMultipleChoiceQuestion < 3) { |
958 checkUnnamed684(o.choices); | 958 checkUnnamed705(o.choices); |
959 } | 959 } |
960 buildCounterMultipleChoiceQuestion--; | 960 buildCounterMultipleChoiceQuestion--; |
961 } | 961 } |
962 | 962 |
963 core.int buildCounterMultipleChoiceSubmission = 0; | 963 core.int buildCounterMultipleChoiceSubmission = 0; |
964 buildMultipleChoiceSubmission() { | 964 buildMultipleChoiceSubmission() { |
965 var o = new api.MultipleChoiceSubmission(); | 965 var o = new api.MultipleChoiceSubmission(); |
966 buildCounterMultipleChoiceSubmission++; | 966 buildCounterMultipleChoiceSubmission++; |
967 if (buildCounterMultipleChoiceSubmission < 3) { | 967 if (buildCounterMultipleChoiceSubmission < 3) { |
968 o.answer = "foo"; | 968 o.answer = "foo"; |
(...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1208 return o; | 1208 return o; |
1209 } | 1209 } |
1210 | 1210 |
1211 checkTurnInStudentSubmissionRequest(api.TurnInStudentSubmissionRequest o) { | 1211 checkTurnInStudentSubmissionRequest(api.TurnInStudentSubmissionRequest o) { |
1212 buildCounterTurnInStudentSubmissionRequest++; | 1212 buildCounterTurnInStudentSubmissionRequest++; |
1213 if (buildCounterTurnInStudentSubmissionRequest < 3) { | 1213 if (buildCounterTurnInStudentSubmissionRequest < 3) { |
1214 } | 1214 } |
1215 buildCounterTurnInStudentSubmissionRequest--; | 1215 buildCounterTurnInStudentSubmissionRequest--; |
1216 } | 1216 } |
1217 | 1217 |
1218 buildUnnamed685() { | 1218 buildUnnamed706() { |
1219 var o = new core.List<api.GlobalPermission>(); | 1219 var o = new core.List<api.GlobalPermission>(); |
1220 o.add(buildGlobalPermission()); | 1220 o.add(buildGlobalPermission()); |
1221 o.add(buildGlobalPermission()); | 1221 o.add(buildGlobalPermission()); |
1222 return o; | 1222 return o; |
1223 } | 1223 } |
1224 | 1224 |
1225 checkUnnamed685(core.List<api.GlobalPermission> o) { | 1225 checkUnnamed706(core.List<api.GlobalPermission> o) { |
1226 unittest.expect(o, unittest.hasLength(2)); | 1226 unittest.expect(o, unittest.hasLength(2)); |
1227 checkGlobalPermission(o[0]); | 1227 checkGlobalPermission(o[0]); |
1228 checkGlobalPermission(o[1]); | 1228 checkGlobalPermission(o[1]); |
1229 } | 1229 } |
1230 | 1230 |
1231 core.int buildCounterUserProfile = 0; | 1231 core.int buildCounterUserProfile = 0; |
1232 buildUserProfile() { | 1232 buildUserProfile() { |
1233 var o = new api.UserProfile(); | 1233 var o = new api.UserProfile(); |
1234 buildCounterUserProfile++; | 1234 buildCounterUserProfile++; |
1235 if (buildCounterUserProfile < 3) { | 1235 if (buildCounterUserProfile < 3) { |
1236 o.emailAddress = "foo"; | 1236 o.emailAddress = "foo"; |
1237 o.id = "foo"; | 1237 o.id = "foo"; |
1238 o.name = buildName(); | 1238 o.name = buildName(); |
1239 o.permissions = buildUnnamed685(); | 1239 o.permissions = buildUnnamed706(); |
1240 o.photoUrl = "foo"; | 1240 o.photoUrl = "foo"; |
1241 } | 1241 } |
1242 buildCounterUserProfile--; | 1242 buildCounterUserProfile--; |
1243 return o; | 1243 return o; |
1244 } | 1244 } |
1245 | 1245 |
1246 checkUserProfile(api.UserProfile o) { | 1246 checkUserProfile(api.UserProfile o) { |
1247 buildCounterUserProfile++; | 1247 buildCounterUserProfile++; |
1248 if (buildCounterUserProfile < 3) { | 1248 if (buildCounterUserProfile < 3) { |
1249 unittest.expect(o.emailAddress, unittest.equals('foo')); | 1249 unittest.expect(o.emailAddress, unittest.equals('foo')); |
1250 unittest.expect(o.id, unittest.equals('foo')); | 1250 unittest.expect(o.id, unittest.equals('foo')); |
1251 checkName(o.name); | 1251 checkName(o.name); |
1252 checkUnnamed685(o.permissions); | 1252 checkUnnamed706(o.permissions); |
1253 unittest.expect(o.photoUrl, unittest.equals('foo')); | 1253 unittest.expect(o.photoUrl, unittest.equals('foo')); |
1254 } | 1254 } |
1255 buildCounterUserProfile--; | 1255 buildCounterUserProfile--; |
1256 } | 1256 } |
1257 | 1257 |
1258 core.int buildCounterYouTubeVideo = 0; | 1258 core.int buildCounterYouTubeVideo = 0; |
1259 buildYouTubeVideo() { | 1259 buildYouTubeVideo() { |
1260 var o = new api.YouTubeVideo(); | 1260 var o = new api.YouTubeVideo(); |
1261 buildCounterYouTubeVideo++; | 1261 buildCounterYouTubeVideo++; |
1262 if (buildCounterYouTubeVideo < 3) { | 1262 if (buildCounterYouTubeVideo < 3) { |
(...skipping 10 matching lines...) Expand all Loading... |
1273 buildCounterYouTubeVideo++; | 1273 buildCounterYouTubeVideo++; |
1274 if (buildCounterYouTubeVideo < 3) { | 1274 if (buildCounterYouTubeVideo < 3) { |
1275 unittest.expect(o.alternateLink, unittest.equals('foo')); | 1275 unittest.expect(o.alternateLink, unittest.equals('foo')); |
1276 unittest.expect(o.id, unittest.equals('foo')); | 1276 unittest.expect(o.id, unittest.equals('foo')); |
1277 unittest.expect(o.thumbnailUrl, unittest.equals('foo')); | 1277 unittest.expect(o.thumbnailUrl, unittest.equals('foo')); |
1278 unittest.expect(o.title, unittest.equals('foo')); | 1278 unittest.expect(o.title, unittest.equals('foo')); |
1279 } | 1279 } |
1280 buildCounterYouTubeVideo--; | 1280 buildCounterYouTubeVideo--; |
1281 } | 1281 } |
1282 | 1282 |
1283 buildUnnamed686() { | 1283 buildUnnamed707() { |
1284 var o = new core.List<core.String>(); | 1284 var o = new core.List<core.String>(); |
1285 o.add("foo"); | 1285 o.add("foo"); |
1286 o.add("foo"); | 1286 o.add("foo"); |
1287 return o; | 1287 return o; |
1288 } | 1288 } |
1289 | 1289 |
1290 checkUnnamed686(core.List<core.String> o) { | 1290 checkUnnamed707(core.List<core.String> o) { |
1291 unittest.expect(o, unittest.hasLength(2)); | 1291 unittest.expect(o, unittest.hasLength(2)); |
1292 unittest.expect(o[0], unittest.equals('foo')); | 1292 unittest.expect(o[0], unittest.equals('foo')); |
1293 unittest.expect(o[1], unittest.equals('foo')); | 1293 unittest.expect(o[1], unittest.equals('foo')); |
1294 } | 1294 } |
1295 | 1295 |
1296 buildUnnamed687() { | 1296 buildUnnamed708() { |
1297 var o = new core.List<core.String>(); | 1297 var o = new core.List<core.String>(); |
1298 o.add("foo"); | 1298 o.add("foo"); |
1299 o.add("foo"); | 1299 o.add("foo"); |
1300 return o; | 1300 return o; |
1301 } | 1301 } |
1302 | 1302 |
1303 checkUnnamed687(core.List<core.String> o) { | 1303 checkUnnamed708(core.List<core.String> o) { |
1304 unittest.expect(o, unittest.hasLength(2)); | 1304 unittest.expect(o, unittest.hasLength(2)); |
1305 unittest.expect(o[0], unittest.equals('foo')); | 1305 unittest.expect(o[0], unittest.equals('foo')); |
1306 unittest.expect(o[1], unittest.equals('foo')); | 1306 unittest.expect(o[1], unittest.equals('foo')); |
1307 } | 1307 } |
1308 | 1308 |
1309 buildUnnamed688() { | 1309 buildUnnamed709() { |
1310 var o = new core.List<core.String>(); | 1310 var o = new core.List<core.String>(); |
1311 o.add("foo"); | 1311 o.add("foo"); |
1312 o.add("foo"); | 1312 o.add("foo"); |
1313 return o; | 1313 return o; |
1314 } | 1314 } |
1315 | 1315 |
1316 checkUnnamed688(core.List<core.String> o) { | 1316 checkUnnamed709(core.List<core.String> o) { |
1317 unittest.expect(o, unittest.hasLength(2)); | 1317 unittest.expect(o, unittest.hasLength(2)); |
1318 unittest.expect(o[0], unittest.equals('foo')); | 1318 unittest.expect(o[0], unittest.equals('foo')); |
1319 unittest.expect(o[1], unittest.equals('foo')); | 1319 unittest.expect(o[1], unittest.equals('foo')); |
1320 } | 1320 } |
1321 | 1321 |
1322 buildUnnamed689() { | 1322 buildUnnamed710() { |
1323 var o = new core.List<core.String>(); | 1323 var o = new core.List<core.String>(); |
1324 o.add("foo"); | 1324 o.add("foo"); |
1325 o.add("foo"); | 1325 o.add("foo"); |
1326 return o; | 1326 return o; |
1327 } | 1327 } |
1328 | 1328 |
1329 checkUnnamed689(core.List<core.String> o) { | 1329 checkUnnamed710(core.List<core.String> o) { |
1330 unittest.expect(o, unittest.hasLength(2)); | 1330 unittest.expect(o, unittest.hasLength(2)); |
1331 unittest.expect(o[0], unittest.equals('foo')); | 1331 unittest.expect(o[0], unittest.equals('foo')); |
1332 unittest.expect(o[1], unittest.equals('foo')); | 1332 unittest.expect(o[1], unittest.equals('foo')); |
1333 } | 1333 } |
1334 | 1334 |
1335 | 1335 |
1336 main() { | 1336 main() { |
1337 unittest.group("obj-schema-Assignment", () { | 1337 unittest.group("obj-schema-Assignment", () { |
1338 unittest.test("to-json--from-json", () { | 1338 unittest.test("to-json--from-json", () { |
1339 var o = buildAssignment(); | 1339 var o = buildAssignment(); |
(...skipping 520 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1860 }), true); | 1860 }), true); |
1861 res.get(arg_id).then(unittest.expectAsync(((api.Course response) { | 1861 res.get(arg_id).then(unittest.expectAsync(((api.Course response) { |
1862 checkCourse(response); | 1862 checkCourse(response); |
1863 }))); | 1863 }))); |
1864 }); | 1864 }); |
1865 | 1865 |
1866 unittest.test("method--list", () { | 1866 unittest.test("method--list", () { |
1867 | 1867 |
1868 var mock = new HttpServerMock(); | 1868 var mock = new HttpServerMock(); |
1869 api.CoursesResourceApi res = new api.ClassroomApi(mock).courses; | 1869 api.CoursesResourceApi res = new api.ClassroomApi(mock).courses; |
| 1870 var arg_courseStates = buildUnnamed707(); |
| 1871 var arg_pageSize = 42; |
| 1872 var arg_teacherId = "foo"; |
1870 var arg_studentId = "foo"; | 1873 var arg_studentId = "foo"; |
1871 var arg_teacherId = "foo"; | |
1872 var arg_courseStates = buildUnnamed686(); | |
1873 var arg_pageSize = 42; | |
1874 var arg_pageToken = "foo"; | 1874 var arg_pageToken = "foo"; |
1875 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 1875 mock.register(unittest.expectAsync((http.BaseRequest req, json) { |
1876 var path = (req.url).path; | 1876 var path = (req.url).path; |
1877 var pathOffset = 0; | 1877 var pathOffset = 0; |
1878 var index; | 1878 var index; |
1879 var subPart; | 1879 var subPart; |
1880 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 1880 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
1881 pathOffset += 1; | 1881 pathOffset += 1; |
1882 unittest.expect(path.substring(pathOffset, pathOffset + 10), unittest.eq
uals("v1/courses")); | 1882 unittest.expect(path.substring(pathOffset, pathOffset + 10), unittest.eq
uals("v1/courses")); |
1883 pathOffset += 10; | 1883 pathOffset += 10; |
1884 | 1884 |
1885 var query = (req.url).query; | 1885 var query = (req.url).query; |
1886 var queryOffset = 0; | 1886 var queryOffset = 0; |
1887 var queryMap = {}; | 1887 var queryMap = {}; |
1888 addQueryParam(n, v) => queryMap.putIfAbsent(n, () => []).add(v); | 1888 addQueryParam(n, v) => queryMap.putIfAbsent(n, () => []).add(v); |
1889 parseBool(n) { | 1889 parseBool(n) { |
1890 if (n == "true") return true; | 1890 if (n == "true") return true; |
1891 if (n == "false") return false; | 1891 if (n == "false") return false; |
1892 if (n == null) return null; | 1892 if (n == null) return null; |
1893 throw new core.ArgumentError("Invalid boolean: $n"); | 1893 throw new core.ArgumentError("Invalid boolean: $n"); |
1894 } | 1894 } |
1895 if (query.length > 0) { | 1895 if (query.length > 0) { |
1896 for (var part in query.split("&")) { | 1896 for (var part in query.split("&")) { |
1897 var keyvalue = part.split("="); | 1897 var keyvalue = part.split("="); |
1898 addQueryParam(core.Uri.decodeQueryComponent(keyvalue[0]), core.Uri.d
ecodeQueryComponent(keyvalue[1])); | 1898 addQueryParam(core.Uri.decodeQueryComponent(keyvalue[0]), core.Uri.d
ecodeQueryComponent(keyvalue[1])); |
1899 } | 1899 } |
1900 } | 1900 } |
1901 unittest.expect(queryMap["studentId"].first, unittest.equals(arg_student
Id)); | |
1902 unittest.expect(queryMap["teacherId"].first, unittest.equals(arg_teacher
Id)); | |
1903 unittest.expect(queryMap["courseStates"], unittest.equals(arg_courseStat
es)); | 1901 unittest.expect(queryMap["courseStates"], unittest.equals(arg_courseStat
es)); |
1904 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); | 1902 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); |
| 1903 unittest.expect(queryMap["teacherId"].first, unittest.equals(arg_teacher
Id)); |
| 1904 unittest.expect(queryMap["studentId"].first, unittest.equals(arg_student
Id)); |
1905 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); | 1905 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); |
1906 | 1906 |
1907 | 1907 |
1908 var h = { | 1908 var h = { |
1909 "content-type" : "application/json; charset=utf-8", | 1909 "content-type" : "application/json; charset=utf-8", |
1910 }; | 1910 }; |
1911 var resp = convert.JSON.encode(buildListCoursesResponse()); | 1911 var resp = convert.JSON.encode(buildListCoursesResponse()); |
1912 return new async.Future.value(stringResponse(200, h, resp)); | 1912 return new async.Future.value(stringResponse(200, h, resp)); |
1913 }), true); | 1913 }), true); |
1914 res.list(studentId: arg_studentId, teacherId: arg_teacherId, courseStates:
arg_courseStates, pageSize: arg_pageSize, pageToken: arg_pageToken).then(unitte
st.expectAsync(((api.ListCoursesResponse response) { | 1914 res.list(courseStates: arg_courseStates, pageSize: arg_pageSize, teacherId
: arg_teacherId, studentId: arg_studentId, pageToken: arg_pageToken).then(unitte
st.expectAsync(((api.ListCoursesResponse response) { |
1915 checkListCoursesResponse(response); | 1915 checkListCoursesResponse(response); |
1916 }))); | 1916 }))); |
1917 }); | 1917 }); |
1918 | 1918 |
1919 unittest.test("method--patch", () { | 1919 unittest.test("method--patch", () { |
1920 | 1920 |
1921 var mock = new HttpServerMock(); | 1921 var mock = new HttpServerMock(); |
1922 api.CoursesResourceApi res = new api.ClassroomApi(mock).courses; | 1922 api.CoursesResourceApi res = new api.ClassroomApi(mock).courses; |
1923 var arg_request = buildCourse(); | 1923 var arg_request = buildCourse(); |
1924 var arg_id = "foo"; | 1924 var arg_id = "foo"; |
(...skipping 431 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2356 res.get(arg_courseId, arg_id).then(unittest.expectAsync(((api.CourseWork r
esponse) { | 2356 res.get(arg_courseId, arg_id).then(unittest.expectAsync(((api.CourseWork r
esponse) { |
2357 checkCourseWork(response); | 2357 checkCourseWork(response); |
2358 }))); | 2358 }))); |
2359 }); | 2359 }); |
2360 | 2360 |
2361 unittest.test("method--list", () { | 2361 unittest.test("method--list", () { |
2362 | 2362 |
2363 var mock = new HttpServerMock(); | 2363 var mock = new HttpServerMock(); |
2364 api.CoursesCourseWorkResourceApi res = new api.ClassroomApi(mock).courses.
courseWork; | 2364 api.CoursesCourseWorkResourceApi res = new api.ClassroomApi(mock).courses.
courseWork; |
2365 var arg_courseId = "foo"; | 2365 var arg_courseId = "foo"; |
2366 var arg_courseWorkStates = buildUnnamed687(); | 2366 var arg_courseWorkStates = buildUnnamed708(); |
| 2367 var arg_pageSize = 42; |
2367 var arg_orderBy = "foo"; | 2368 var arg_orderBy = "foo"; |
2368 var arg_pageSize = 42; | |
2369 var arg_pageToken = "foo"; | 2369 var arg_pageToken = "foo"; |
2370 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2370 mock.register(unittest.expectAsync((http.BaseRequest req, json) { |
2371 var path = (req.url).path; | 2371 var path = (req.url).path; |
2372 var pathOffset = 0; | 2372 var pathOffset = 0; |
2373 var index; | 2373 var index; |
2374 var subPart; | 2374 var subPart; |
2375 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2375 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2376 pathOffset += 1; | 2376 pathOffset += 1; |
2377 unittest.expect(path.substring(pathOffset, pathOffset + 11), unittest.eq
uals("v1/courses/")); | 2377 unittest.expect(path.substring(pathOffset, pathOffset + 11), unittest.eq
uals("v1/courses/")); |
2378 pathOffset += 11; | 2378 pathOffset += 11; |
(...skipping 15 matching lines...) Expand all Loading... |
2394 if (n == null) return null; | 2394 if (n == null) return null; |
2395 throw new core.ArgumentError("Invalid boolean: $n"); | 2395 throw new core.ArgumentError("Invalid boolean: $n"); |
2396 } | 2396 } |
2397 if (query.length > 0) { | 2397 if (query.length > 0) { |
2398 for (var part in query.split("&")) { | 2398 for (var part in query.split("&")) { |
2399 var keyvalue = part.split("="); | 2399 var keyvalue = part.split("="); |
2400 addQueryParam(core.Uri.decodeQueryComponent(keyvalue[0]), core.Uri.d
ecodeQueryComponent(keyvalue[1])); | 2400 addQueryParam(core.Uri.decodeQueryComponent(keyvalue[0]), core.Uri.d
ecodeQueryComponent(keyvalue[1])); |
2401 } | 2401 } |
2402 } | 2402 } |
2403 unittest.expect(queryMap["courseWorkStates"], unittest.equals(arg_course
WorkStates)); | 2403 unittest.expect(queryMap["courseWorkStates"], unittest.equals(arg_course
WorkStates)); |
| 2404 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); |
2404 unittest.expect(queryMap["orderBy"].first, unittest.equals(arg_orderBy))
; | 2405 unittest.expect(queryMap["orderBy"].first, unittest.equals(arg_orderBy))
; |
2405 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); | |
2406 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); | 2406 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); |
2407 | 2407 |
2408 | 2408 |
2409 var h = { | 2409 var h = { |
2410 "content-type" : "application/json; charset=utf-8", | 2410 "content-type" : "application/json; charset=utf-8", |
2411 }; | 2411 }; |
2412 var resp = convert.JSON.encode(buildListCourseWorkResponse()); | 2412 var resp = convert.JSON.encode(buildListCourseWorkResponse()); |
2413 return new async.Future.value(stringResponse(200, h, resp)); | 2413 return new async.Future.value(stringResponse(200, h, resp)); |
2414 }), true); | 2414 }), true); |
2415 res.list(arg_courseId, courseWorkStates: arg_courseWorkStates, orderBy: ar
g_orderBy, pageSize: arg_pageSize, pageToken: arg_pageToken).then(unittest.expec
tAsync(((api.ListCourseWorkResponse response) { | 2415 res.list(arg_courseId, courseWorkStates: arg_courseWorkStates, pageSize: a
rg_pageSize, orderBy: arg_orderBy, pageToken: arg_pageToken).then(unittest.expec
tAsync(((api.ListCourseWorkResponse response) { |
2416 checkListCourseWorkResponse(response); | 2416 checkListCourseWorkResponse(response); |
2417 }))); | 2417 }))); |
2418 }); | 2418 }); |
2419 | 2419 |
2420 unittest.test("method--patch", () { | 2420 unittest.test("method--patch", () { |
2421 | 2421 |
2422 var mock = new HttpServerMock(); | 2422 var mock = new HttpServerMock(); |
2423 api.CoursesCourseWorkResourceApi res = new api.ClassroomApi(mock).courses.
courseWork; | 2423 api.CoursesCourseWorkResourceApi res = new api.ClassroomApi(mock).courses.
courseWork; |
2424 var arg_request = buildCourseWork(); | 2424 var arg_request = buildCourseWork(); |
2425 var arg_courseId = "foo"; | 2425 var arg_courseId = "foo"; |
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2544 checkStudentSubmission(response); | 2544 checkStudentSubmission(response); |
2545 }))); | 2545 }))); |
2546 }); | 2546 }); |
2547 | 2547 |
2548 unittest.test("method--list", () { | 2548 unittest.test("method--list", () { |
2549 | 2549 |
2550 var mock = new HttpServerMock(); | 2550 var mock = new HttpServerMock(); |
2551 api.CoursesCourseWorkStudentSubmissionsResourceApi res = new api.Classroom
Api(mock).courses.courseWork.studentSubmissions; | 2551 api.CoursesCourseWorkStudentSubmissionsResourceApi res = new api.Classroom
Api(mock).courses.courseWork.studentSubmissions; |
2552 var arg_courseId = "foo"; | 2552 var arg_courseId = "foo"; |
2553 var arg_courseWorkId = "foo"; | 2553 var arg_courseWorkId = "foo"; |
| 2554 var arg_states = buildUnnamed709(); |
2554 var arg_userId = "foo"; | 2555 var arg_userId = "foo"; |
2555 var arg_states = buildUnnamed688(); | 2556 var arg_pageSize = 42; |
2556 var arg_late = "foo"; | 2557 var arg_late = "foo"; |
2557 var arg_pageSize = 42; | |
2558 var arg_pageToken = "foo"; | 2558 var arg_pageToken = "foo"; |
2559 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 2559 mock.register(unittest.expectAsync((http.BaseRequest req, json) { |
2560 var path = (req.url).path; | 2560 var path = (req.url).path; |
2561 var pathOffset = 0; | 2561 var pathOffset = 0; |
2562 var index; | 2562 var index; |
2563 var subPart; | 2563 var subPart; |
2564 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 2564 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
2565 pathOffset += 1; | 2565 pathOffset += 1; |
2566 unittest.expect(path.substring(pathOffset, pathOffset + 11), unittest.eq
uals("v1/courses/")); | 2566 unittest.expect(path.substring(pathOffset, pathOffset + 11), unittest.eq
uals("v1/courses/")); |
2567 pathOffset += 11; | 2567 pathOffset += 11; |
(...skipping 21 matching lines...) Expand all Loading... |
2589 if (n == "false") return false; | 2589 if (n == "false") return false; |
2590 if (n == null) return null; | 2590 if (n == null) return null; |
2591 throw new core.ArgumentError("Invalid boolean: $n"); | 2591 throw new core.ArgumentError("Invalid boolean: $n"); |
2592 } | 2592 } |
2593 if (query.length > 0) { | 2593 if (query.length > 0) { |
2594 for (var part in query.split("&")) { | 2594 for (var part in query.split("&")) { |
2595 var keyvalue = part.split("="); | 2595 var keyvalue = part.split("="); |
2596 addQueryParam(core.Uri.decodeQueryComponent(keyvalue[0]), core.Uri.d
ecodeQueryComponent(keyvalue[1])); | 2596 addQueryParam(core.Uri.decodeQueryComponent(keyvalue[0]), core.Uri.d
ecodeQueryComponent(keyvalue[1])); |
2597 } | 2597 } |
2598 } | 2598 } |
| 2599 unittest.expect(queryMap["states"], unittest.equals(arg_states)); |
2599 unittest.expect(queryMap["userId"].first, unittest.equals(arg_userId)); | 2600 unittest.expect(queryMap["userId"].first, unittest.equals(arg_userId)); |
2600 unittest.expect(queryMap["states"], unittest.equals(arg_states)); | 2601 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); |
2601 unittest.expect(queryMap["late"].first, unittest.equals(arg_late)); | 2602 unittest.expect(queryMap["late"].first, unittest.equals(arg_late)); |
2602 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); | |
2603 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); | 2603 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); |
2604 | 2604 |
2605 | 2605 |
2606 var h = { | 2606 var h = { |
2607 "content-type" : "application/json; charset=utf-8", | 2607 "content-type" : "application/json; charset=utf-8", |
2608 }; | 2608 }; |
2609 var resp = convert.JSON.encode(buildListStudentSubmissionsResponse()); | 2609 var resp = convert.JSON.encode(buildListStudentSubmissionsResponse()); |
2610 return new async.Future.value(stringResponse(200, h, resp)); | 2610 return new async.Future.value(stringResponse(200, h, resp)); |
2611 }), true); | 2611 }), true); |
2612 res.list(arg_courseId, arg_courseWorkId, userId: arg_userId, states: arg_s
tates, late: arg_late, pageSize: arg_pageSize, pageToken: arg_pageToken).then(un
ittest.expectAsync(((api.ListStudentSubmissionsResponse response) { | 2612 res.list(arg_courseId, arg_courseWorkId, states: arg_states, userId: arg_u
serId, pageSize: arg_pageSize, late: arg_late, pageToken: arg_pageToken).then(un
ittest.expectAsync(((api.ListStudentSubmissionsResponse response) { |
2613 checkListStudentSubmissionsResponse(response); | 2613 checkListStudentSubmissionsResponse(response); |
2614 }))); | 2614 }))); |
2615 }); | 2615 }); |
2616 | 2616 |
2617 unittest.test("method--modifyAttachments", () { | 2617 unittest.test("method--modifyAttachments", () { |
2618 | 2618 |
2619 var mock = new HttpServerMock(); | 2619 var mock = new HttpServerMock(); |
2620 api.CoursesCourseWorkStudentSubmissionsResourceApi res = new api.Classroom
Api(mock).courses.courseWork.studentSubmissions; | 2620 api.CoursesCourseWorkStudentSubmissionsResourceApi res = new api.Classroom
Api(mock).courses.courseWork.studentSubmissions; |
2621 var arg_request = buildModifyAttachmentsRequest(); | 2621 var arg_request = buildModifyAttachmentsRequest(); |
2622 var arg_courseId = "foo"; | 2622 var arg_courseId = "foo"; |
(...skipping 987 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3610 }), true); | 3610 }), true); |
3611 res.get(arg_id).then(unittest.expectAsync(((api.Invitation response) { | 3611 res.get(arg_id).then(unittest.expectAsync(((api.Invitation response) { |
3612 checkInvitation(response); | 3612 checkInvitation(response); |
3613 }))); | 3613 }))); |
3614 }); | 3614 }); |
3615 | 3615 |
3616 unittest.test("method--list", () { | 3616 unittest.test("method--list", () { |
3617 | 3617 |
3618 var mock = new HttpServerMock(); | 3618 var mock = new HttpServerMock(); |
3619 api.InvitationsResourceApi res = new api.ClassroomApi(mock).invitations; | 3619 api.InvitationsResourceApi res = new api.ClassroomApi(mock).invitations; |
3620 var arg_userId = "foo"; | |
3621 var arg_courseId = "foo"; | 3620 var arg_courseId = "foo"; |
3622 var arg_pageSize = 42; | 3621 var arg_pageSize = 42; |
| 3622 var arg_userId = "foo"; |
3623 var arg_pageToken = "foo"; | 3623 var arg_pageToken = "foo"; |
3624 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3624 mock.register(unittest.expectAsync((http.BaseRequest req, json) { |
3625 var path = (req.url).path; | 3625 var path = (req.url).path; |
3626 var pathOffset = 0; | 3626 var pathOffset = 0; |
3627 var index; | 3627 var index; |
3628 var subPart; | 3628 var subPart; |
3629 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3629 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3630 pathOffset += 1; | 3630 pathOffset += 1; |
3631 unittest.expect(path.substring(pathOffset, pathOffset + 14), unittest.eq
uals("v1/invitations")); | 3631 unittest.expect(path.substring(pathOffset, pathOffset + 14), unittest.eq
uals("v1/invitations")); |
3632 pathOffset += 14; | 3632 pathOffset += 14; |
3633 | 3633 |
3634 var query = (req.url).query; | 3634 var query = (req.url).query; |
3635 var queryOffset = 0; | 3635 var queryOffset = 0; |
3636 var queryMap = {}; | 3636 var queryMap = {}; |
3637 addQueryParam(n, v) => queryMap.putIfAbsent(n, () => []).add(v); | 3637 addQueryParam(n, v) => queryMap.putIfAbsent(n, () => []).add(v); |
3638 parseBool(n) { | 3638 parseBool(n) { |
3639 if (n == "true") return true; | 3639 if (n == "true") return true; |
3640 if (n == "false") return false; | 3640 if (n == "false") return false; |
3641 if (n == null) return null; | 3641 if (n == null) return null; |
3642 throw new core.ArgumentError("Invalid boolean: $n"); | 3642 throw new core.ArgumentError("Invalid boolean: $n"); |
3643 } | 3643 } |
3644 if (query.length > 0) { | 3644 if (query.length > 0) { |
3645 for (var part in query.split("&")) { | 3645 for (var part in query.split("&")) { |
3646 var keyvalue = part.split("="); | 3646 var keyvalue = part.split("="); |
3647 addQueryParam(core.Uri.decodeQueryComponent(keyvalue[0]), core.Uri.d
ecodeQueryComponent(keyvalue[1])); | 3647 addQueryParam(core.Uri.decodeQueryComponent(keyvalue[0]), core.Uri.d
ecodeQueryComponent(keyvalue[1])); |
3648 } | 3648 } |
3649 } | 3649 } |
3650 unittest.expect(queryMap["userId"].first, unittest.equals(arg_userId)); | |
3651 unittest.expect(queryMap["courseId"].first, unittest.equals(arg_courseId
)); | 3650 unittest.expect(queryMap["courseId"].first, unittest.equals(arg_courseId
)); |
3652 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); | 3651 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); |
| 3652 unittest.expect(queryMap["userId"].first, unittest.equals(arg_userId)); |
3653 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); | 3653 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); |
3654 | 3654 |
3655 | 3655 |
3656 var h = { | 3656 var h = { |
3657 "content-type" : "application/json; charset=utf-8", | 3657 "content-type" : "application/json; charset=utf-8", |
3658 }; | 3658 }; |
3659 var resp = convert.JSON.encode(buildListInvitationsResponse()); | 3659 var resp = convert.JSON.encode(buildListInvitationsResponse()); |
3660 return new async.Future.value(stringResponse(200, h, resp)); | 3660 return new async.Future.value(stringResponse(200, h, resp)); |
3661 }), true); | 3661 }), true); |
3662 res.list(userId: arg_userId, courseId: arg_courseId, pageSize: arg_pageSiz
e, pageToken: arg_pageToken).then(unittest.expectAsync(((api.ListInvitationsResp
onse response) { | 3662 res.list(courseId: arg_courseId, pageSize: arg_pageSize, userId: arg_userI
d, pageToken: arg_pageToken).then(unittest.expectAsync(((api.ListInvitationsResp
onse response) { |
3663 checkListInvitationsResponse(response); | 3663 checkListInvitationsResponse(response); |
3664 }))); | 3664 }))); |
3665 }); | 3665 }); |
3666 | 3666 |
3667 }); | 3667 }); |
3668 | 3668 |
3669 | 3669 |
3670 unittest.group("resource-UserProfilesResourceApi", () { | 3670 unittest.group("resource-UserProfilesResourceApi", () { |
3671 unittest.test("method--get", () { | 3671 unittest.test("method--get", () { |
3672 | 3672 |
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3827 res.get(arg_studentId, arg_invitationId).then(unittest.expectAsync(((api.G
uardianInvitation response) { | 3827 res.get(arg_studentId, arg_invitationId).then(unittest.expectAsync(((api.G
uardianInvitation response) { |
3828 checkGuardianInvitation(response); | 3828 checkGuardianInvitation(response); |
3829 }))); | 3829 }))); |
3830 }); | 3830 }); |
3831 | 3831 |
3832 unittest.test("method--list", () { | 3832 unittest.test("method--list", () { |
3833 | 3833 |
3834 var mock = new HttpServerMock(); | 3834 var mock = new HttpServerMock(); |
3835 api.UserProfilesGuardianInvitationsResourceApi res = new api.ClassroomApi(
mock).userProfiles.guardianInvitations; | 3835 api.UserProfilesGuardianInvitationsResourceApi res = new api.ClassroomApi(
mock).userProfiles.guardianInvitations; |
3836 var arg_studentId = "foo"; | 3836 var arg_studentId = "foo"; |
| 3837 var arg_pageSize = 42; |
3837 var arg_invitedEmailAddress = "foo"; | 3838 var arg_invitedEmailAddress = "foo"; |
3838 var arg_states = buildUnnamed689(); | 3839 var arg_states = buildUnnamed710(); |
3839 var arg_pageToken = "foo"; | 3840 var arg_pageToken = "foo"; |
3840 var arg_pageSize = 42; | |
3841 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 3841 mock.register(unittest.expectAsync((http.BaseRequest req, json) { |
3842 var path = (req.url).path; | 3842 var path = (req.url).path; |
3843 var pathOffset = 0; | 3843 var pathOffset = 0; |
3844 var index; | 3844 var index; |
3845 var subPart; | 3845 var subPart; |
3846 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 3846 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
3847 pathOffset += 1; | 3847 pathOffset += 1; |
3848 unittest.expect(path.substring(pathOffset, pathOffset + 16), unittest.eq
uals("v1/userProfiles/")); | 3848 unittest.expect(path.substring(pathOffset, pathOffset + 16), unittest.eq
uals("v1/userProfiles/")); |
3849 pathOffset += 16; | 3849 pathOffset += 16; |
3850 index = path.indexOf("/guardianInvitations", pathOffset); | 3850 index = path.indexOf("/guardianInvitations", pathOffset); |
(...skipping 13 matching lines...) Expand all Loading... |
3864 if (n == "false") return false; | 3864 if (n == "false") return false; |
3865 if (n == null) return null; | 3865 if (n == null) return null; |
3866 throw new core.ArgumentError("Invalid boolean: $n"); | 3866 throw new core.ArgumentError("Invalid boolean: $n"); |
3867 } | 3867 } |
3868 if (query.length > 0) { | 3868 if (query.length > 0) { |
3869 for (var part in query.split("&")) { | 3869 for (var part in query.split("&")) { |
3870 var keyvalue = part.split("="); | 3870 var keyvalue = part.split("="); |
3871 addQueryParam(core.Uri.decodeQueryComponent(keyvalue[0]), core.Uri.d
ecodeQueryComponent(keyvalue[1])); | 3871 addQueryParam(core.Uri.decodeQueryComponent(keyvalue[0]), core.Uri.d
ecodeQueryComponent(keyvalue[1])); |
3872 } | 3872 } |
3873 } | 3873 } |
| 3874 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); |
3874 unittest.expect(queryMap["invitedEmailAddress"].first, unittest.equals(a
rg_invitedEmailAddress)); | 3875 unittest.expect(queryMap["invitedEmailAddress"].first, unittest.equals(a
rg_invitedEmailAddress)); |
3875 unittest.expect(queryMap["states"], unittest.equals(arg_states)); | 3876 unittest.expect(queryMap["states"], unittest.equals(arg_states)); |
3876 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); | 3877 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); |
3877 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); | |
3878 | 3878 |
3879 | 3879 |
3880 var h = { | 3880 var h = { |
3881 "content-type" : "application/json; charset=utf-8", | 3881 "content-type" : "application/json; charset=utf-8", |
3882 }; | 3882 }; |
3883 var resp = convert.JSON.encode(buildListGuardianInvitationsResponse()); | 3883 var resp = convert.JSON.encode(buildListGuardianInvitationsResponse()); |
3884 return new async.Future.value(stringResponse(200, h, resp)); | 3884 return new async.Future.value(stringResponse(200, h, resp)); |
3885 }), true); | 3885 }), true); |
3886 res.list(arg_studentId, invitedEmailAddress: arg_invitedEmailAddress, stat
es: arg_states, pageToken: arg_pageToken, pageSize: arg_pageSize).then(unittest.
expectAsync(((api.ListGuardianInvitationsResponse response) { | 3886 res.list(arg_studentId, pageSize: arg_pageSize, invitedEmailAddress: arg_i
nvitedEmailAddress, states: arg_states, pageToken: arg_pageToken).then(unittest.
expectAsync(((api.ListGuardianInvitationsResponse response) { |
3887 checkListGuardianInvitationsResponse(response); | 3887 checkListGuardianInvitationsResponse(response); |
3888 }))); | 3888 }))); |
3889 }); | 3889 }); |
3890 | 3890 |
3891 unittest.test("method--patch", () { | 3891 unittest.test("method--patch", () { |
3892 | 3892 |
3893 var mock = new HttpServerMock(); | 3893 var mock = new HttpServerMock(); |
3894 api.UserProfilesGuardianInvitationsResourceApi res = new api.ClassroomApi(
mock).userProfiles.guardianInvitations; | 3894 api.UserProfilesGuardianInvitationsResourceApi res = new api.ClassroomApi(
mock).userProfiles.guardianInvitations; |
3895 var arg_request = buildGuardianInvitation(); | 3895 var arg_request = buildGuardianInvitation(); |
3896 var arg_studentId = "foo"; | 3896 var arg_studentId = "foo"; |
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4061 res.get(arg_studentId, arg_guardianId).then(unittest.expectAsync(((api.Gua
rdian response) { | 4061 res.get(arg_studentId, arg_guardianId).then(unittest.expectAsync(((api.Gua
rdian response) { |
4062 checkGuardian(response); | 4062 checkGuardian(response); |
4063 }))); | 4063 }))); |
4064 }); | 4064 }); |
4065 | 4065 |
4066 unittest.test("method--list", () { | 4066 unittest.test("method--list", () { |
4067 | 4067 |
4068 var mock = new HttpServerMock(); | 4068 var mock = new HttpServerMock(); |
4069 api.UserProfilesGuardiansResourceApi res = new api.ClassroomApi(mock).user
Profiles.guardians; | 4069 api.UserProfilesGuardiansResourceApi res = new api.ClassroomApi(mock).user
Profiles.guardians; |
4070 var arg_studentId = "foo"; | 4070 var arg_studentId = "foo"; |
| 4071 var arg_pageSize = 42; |
4071 var arg_invitedEmailAddress = "foo"; | 4072 var arg_invitedEmailAddress = "foo"; |
4072 var arg_pageToken = "foo"; | 4073 var arg_pageToken = "foo"; |
4073 var arg_pageSize = 42; | |
4074 mock.register(unittest.expectAsync((http.BaseRequest req, json) { | 4074 mock.register(unittest.expectAsync((http.BaseRequest req, json) { |
4075 var path = (req.url).path; | 4075 var path = (req.url).path; |
4076 var pathOffset = 0; | 4076 var pathOffset = 0; |
4077 var index; | 4077 var index; |
4078 var subPart; | 4078 var subPart; |
4079 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); | 4079 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ
als("/")); |
4080 pathOffset += 1; | 4080 pathOffset += 1; |
4081 unittest.expect(path.substring(pathOffset, pathOffset + 16), unittest.eq
uals("v1/userProfiles/")); | 4081 unittest.expect(path.substring(pathOffset, pathOffset + 16), unittest.eq
uals("v1/userProfiles/")); |
4082 pathOffset += 16; | 4082 pathOffset += 16; |
4083 index = path.indexOf("/guardians", pathOffset); | 4083 index = path.indexOf("/guardians", pathOffset); |
(...skipping 13 matching lines...) Expand all Loading... |
4097 if (n == "false") return false; | 4097 if (n == "false") return false; |
4098 if (n == null) return null; | 4098 if (n == null) return null; |
4099 throw new core.ArgumentError("Invalid boolean: $n"); | 4099 throw new core.ArgumentError("Invalid boolean: $n"); |
4100 } | 4100 } |
4101 if (query.length > 0) { | 4101 if (query.length > 0) { |
4102 for (var part in query.split("&")) { | 4102 for (var part in query.split("&")) { |
4103 var keyvalue = part.split("="); | 4103 var keyvalue = part.split("="); |
4104 addQueryParam(core.Uri.decodeQueryComponent(keyvalue[0]), core.Uri.d
ecodeQueryComponent(keyvalue[1])); | 4104 addQueryParam(core.Uri.decodeQueryComponent(keyvalue[0]), core.Uri.d
ecodeQueryComponent(keyvalue[1])); |
4105 } | 4105 } |
4106 } | 4106 } |
| 4107 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); |
4107 unittest.expect(queryMap["invitedEmailAddress"].first, unittest.equals(a
rg_invitedEmailAddress)); | 4108 unittest.expect(queryMap["invitedEmailAddress"].first, unittest.equals(a
rg_invitedEmailAddress)); |
4108 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); | 4109 unittest.expect(queryMap["pageToken"].first, unittest.equals(arg_pageTok
en)); |
4109 unittest.expect(core.int.parse(queryMap["pageSize"].first), unittest.equ
als(arg_pageSize)); | |
4110 | 4110 |
4111 | 4111 |
4112 var h = { | 4112 var h = { |
4113 "content-type" : "application/json; charset=utf-8", | 4113 "content-type" : "application/json; charset=utf-8", |
4114 }; | 4114 }; |
4115 var resp = convert.JSON.encode(buildListGuardiansResponse()); | 4115 var resp = convert.JSON.encode(buildListGuardiansResponse()); |
4116 return new async.Future.value(stringResponse(200, h, resp)); | 4116 return new async.Future.value(stringResponse(200, h, resp)); |
4117 }), true); | 4117 }), true); |
4118 res.list(arg_studentId, invitedEmailAddress: arg_invitedEmailAddress, page
Token: arg_pageToken, pageSize: arg_pageSize).then(unittest.expectAsync(((api.Li
stGuardiansResponse response) { | 4118 res.list(arg_studentId, pageSize: arg_pageSize, invitedEmailAddress: arg_i
nvitedEmailAddress, pageToken: arg_pageToken).then(unittest.expectAsync(((api.Li
stGuardiansResponse response) { |
4119 checkListGuardiansResponse(response); | 4119 checkListGuardiansResponse(response); |
4120 }))); | 4120 }))); |
4121 }); | 4121 }); |
4122 | 4122 |
4123 }); | 4123 }); |
4124 | 4124 |
4125 | 4125 |
4126 } | 4126 } |
4127 | 4127 |
OLD | NEW |