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

Side by Side Diff: generated/googleapis/test/youtubeanalytics/v1_test.dart

Issue 595873002: Api roll 1: 2014-09-23 (Closed) Base URL: git@github.com:dart-lang/googleapis.git@master
Patch Set: Created 6 years, 2 months 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
« no previous file with comments | « generated/googleapis/test/youtube/v3_test.dart ('k') | generated/googleapis_beta/CHANGELOG.md » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 library googleapis.youtubeAnalytics.v1.test; 1 library googleapis.youtubeAnalytics.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;
11 import 'package:googleapis/common/common.dart' as common; 11 import 'package:googleapis/common/common.dart' as common;
12 import 'package:googleapis/src/common_internal.dart' as common_internal; 12 import 'package:googleapis/src/common_internal.dart' as common_internal;
13 import '../common/common_internal_test.dart' as common_test; 13 import '../common/common_internal_test.dart' as common_test;
14 14
15 import 'package:googleapis/youtubeanalytics/v1.dart' as api; 15 import 'package:googleapis/youtubeanalytics/v1.dart' as api;
16 16
17 17
18 18
19 buildUnnamed204() { 19 buildUnnamed207() {
20 var o = new core.List<api.BatchReportDefinitionTemplate>(); 20 var o = new core.List<api.BatchReportDefinitionTemplate>();
21 o.add(buildBatchReportDefinitionTemplate()); 21 o.add(buildBatchReportDefinitionTemplate());
22 o.add(buildBatchReportDefinitionTemplate()); 22 o.add(buildBatchReportDefinitionTemplate());
23 return o; 23 return o;
24 } 24 }
25 25
26 checkUnnamed204(core.List<api.BatchReportDefinitionTemplate> o) { 26 checkUnnamed207(core.List<api.BatchReportDefinitionTemplate> o) {
27 unittest.expect(o, unittest.hasLength(2)); 27 unittest.expect(o, unittest.hasLength(2));
28 checkBatchReportDefinitionTemplate(o[0]); 28 checkBatchReportDefinitionTemplate(o[0]);
29 checkBatchReportDefinitionTemplate(o[1]); 29 checkBatchReportDefinitionTemplate(o[1]);
30 } 30 }
31 31
32 core.int buildCounterBatchReportDefinitionList = 0; 32 core.int buildCounterBatchReportDefinitionList = 0;
33 buildBatchReportDefinitionList() { 33 buildBatchReportDefinitionList() {
34 var o = new api.BatchReportDefinitionList(); 34 var o = new api.BatchReportDefinitionList();
35 buildCounterBatchReportDefinitionList++; 35 buildCounterBatchReportDefinitionList++;
36 if (buildCounterBatchReportDefinitionList < 3) { 36 if (buildCounterBatchReportDefinitionList < 3) {
37 o.items = buildUnnamed204(); 37 o.items = buildUnnamed207();
38 o.kind = "foo"; 38 o.kind = "foo";
39 } 39 }
40 buildCounterBatchReportDefinitionList--; 40 buildCounterBatchReportDefinitionList--;
41 return o; 41 return o;
42 } 42 }
43 43
44 checkBatchReportDefinitionList(api.BatchReportDefinitionList o) { 44 checkBatchReportDefinitionList(api.BatchReportDefinitionList o) {
45 buildCounterBatchReportDefinitionList++; 45 buildCounterBatchReportDefinitionList++;
46 if (buildCounterBatchReportDefinitionList < 3) { 46 if (buildCounterBatchReportDefinitionList < 3) {
47 checkUnnamed204(o.items); 47 checkUnnamed207(o.items);
48 unittest.expect(o.kind, unittest.equals('foo')); 48 unittest.expect(o.kind, unittest.equals('foo'));
49 } 49 }
50 buildCounterBatchReportDefinitionList--; 50 buildCounterBatchReportDefinitionList--;
51 } 51 }
52 52
53 core.int buildCounterBatchReportDefinitionTemplateDefaultOutput = 0; 53 core.int buildCounterBatchReportDefinitionTemplateDefaultOutput = 0;
54 buildBatchReportDefinitionTemplateDefaultOutput() { 54 buildBatchReportDefinitionTemplateDefaultOutput() {
55 var o = new api.BatchReportDefinitionTemplateDefaultOutput(); 55 var o = new api.BatchReportDefinitionTemplateDefaultOutput();
56 buildCounterBatchReportDefinitionTemplateDefaultOutput++; 56 buildCounterBatchReportDefinitionTemplateDefaultOutput++;
57 if (buildCounterBatchReportDefinitionTemplateDefaultOutput < 3) { 57 if (buildCounterBatchReportDefinitionTemplateDefaultOutput < 3) {
58 o.format = "foo"; 58 o.format = "foo";
59 o.type = "foo"; 59 o.type = "foo";
60 } 60 }
61 buildCounterBatchReportDefinitionTemplateDefaultOutput--; 61 buildCounterBatchReportDefinitionTemplateDefaultOutput--;
62 return o; 62 return o;
63 } 63 }
64 64
65 checkBatchReportDefinitionTemplateDefaultOutput(api.BatchReportDefinitionTemplat eDefaultOutput o) { 65 checkBatchReportDefinitionTemplateDefaultOutput(api.BatchReportDefinitionTemplat eDefaultOutput o) {
66 buildCounterBatchReportDefinitionTemplateDefaultOutput++; 66 buildCounterBatchReportDefinitionTemplateDefaultOutput++;
67 if (buildCounterBatchReportDefinitionTemplateDefaultOutput < 3) { 67 if (buildCounterBatchReportDefinitionTemplateDefaultOutput < 3) {
68 unittest.expect(o.format, unittest.equals('foo')); 68 unittest.expect(o.format, unittest.equals('foo'));
69 unittest.expect(o.type, unittest.equals('foo')); 69 unittest.expect(o.type, unittest.equals('foo'));
70 } 70 }
71 buildCounterBatchReportDefinitionTemplateDefaultOutput--; 71 buildCounterBatchReportDefinitionTemplateDefaultOutput--;
72 } 72 }
73 73
74 buildUnnamed205() { 74 buildUnnamed208() {
75 var o = new core.List<api.BatchReportDefinitionTemplateDefaultOutput>(); 75 var o = new core.List<api.BatchReportDefinitionTemplateDefaultOutput>();
76 o.add(buildBatchReportDefinitionTemplateDefaultOutput()); 76 o.add(buildBatchReportDefinitionTemplateDefaultOutput());
77 o.add(buildBatchReportDefinitionTemplateDefaultOutput()); 77 o.add(buildBatchReportDefinitionTemplateDefaultOutput());
78 return o; 78 return o;
79 } 79 }
80 80
81 checkUnnamed205(core.List<api.BatchReportDefinitionTemplateDefaultOutput> o) { 81 checkUnnamed208(core.List<api.BatchReportDefinitionTemplateDefaultOutput> o) {
82 unittest.expect(o, unittest.hasLength(2)); 82 unittest.expect(o, unittest.hasLength(2));
83 checkBatchReportDefinitionTemplateDefaultOutput(o[0]); 83 checkBatchReportDefinitionTemplateDefaultOutput(o[0]);
84 checkBatchReportDefinitionTemplateDefaultOutput(o[1]); 84 checkBatchReportDefinitionTemplateDefaultOutput(o[1]);
85 } 85 }
86 86
87 core.int buildCounterBatchReportDefinitionTemplate = 0; 87 core.int buildCounterBatchReportDefinitionTemplate = 0;
88 buildBatchReportDefinitionTemplate() { 88 buildBatchReportDefinitionTemplate() {
89 var o = new api.BatchReportDefinitionTemplate(); 89 var o = new api.BatchReportDefinitionTemplate();
90 buildCounterBatchReportDefinitionTemplate++; 90 buildCounterBatchReportDefinitionTemplate++;
91 if (buildCounterBatchReportDefinitionTemplate < 3) { 91 if (buildCounterBatchReportDefinitionTemplate < 3) {
92 o.defaultOutput = buildUnnamed205(); 92 o.defaultOutput = buildUnnamed208();
93 o.id = "foo"; 93 o.id = "foo";
94 o.name = "foo"; 94 o.name = "foo";
95 o.status = "foo"; 95 o.status = "foo";
96 o.type = "foo"; 96 o.type = "foo";
97 } 97 }
98 buildCounterBatchReportDefinitionTemplate--; 98 buildCounterBatchReportDefinitionTemplate--;
99 return o; 99 return o;
100 } 100 }
101 101
102 checkBatchReportDefinitionTemplate(api.BatchReportDefinitionTemplate o) { 102 checkBatchReportDefinitionTemplate(api.BatchReportDefinitionTemplate o) {
103 buildCounterBatchReportDefinitionTemplate++; 103 buildCounterBatchReportDefinitionTemplate++;
104 if (buildCounterBatchReportDefinitionTemplate < 3) { 104 if (buildCounterBatchReportDefinitionTemplate < 3) {
105 checkUnnamed205(o.defaultOutput); 105 checkUnnamed208(o.defaultOutput);
106 unittest.expect(o.id, unittest.equals('foo')); 106 unittest.expect(o.id, unittest.equals('foo'));
107 unittest.expect(o.name, unittest.equals('foo')); 107 unittest.expect(o.name, unittest.equals('foo'));
108 unittest.expect(o.status, unittest.equals('foo')); 108 unittest.expect(o.status, unittest.equals('foo'));
109 unittest.expect(o.type, unittest.equals('foo')); 109 unittest.expect(o.type, unittest.equals('foo'));
110 } 110 }
111 buildCounterBatchReportDefinitionTemplate--; 111 buildCounterBatchReportDefinitionTemplate--;
112 } 112 }
113 113
114 buildUnnamed206() { 114 buildUnnamed209() {
115 var o = new core.List<api.BatchReportTemplate>(); 115 var o = new core.List<api.BatchReportTemplate>();
116 o.add(buildBatchReportTemplate()); 116 o.add(buildBatchReportTemplate());
117 o.add(buildBatchReportTemplate()); 117 o.add(buildBatchReportTemplate());
118 return o; 118 return o;
119 } 119 }
120 120
121 checkUnnamed206(core.List<api.BatchReportTemplate> o) { 121 checkUnnamed209(core.List<api.BatchReportTemplate> o) {
122 unittest.expect(o, unittest.hasLength(2)); 122 unittest.expect(o, unittest.hasLength(2));
123 checkBatchReportTemplate(o[0]); 123 checkBatchReportTemplate(o[0]);
124 checkBatchReportTemplate(o[1]); 124 checkBatchReportTemplate(o[1]);
125 } 125 }
126 126
127 core.int buildCounterBatchReportList = 0; 127 core.int buildCounterBatchReportList = 0;
128 buildBatchReportList() { 128 buildBatchReportList() {
129 var o = new api.BatchReportList(); 129 var o = new api.BatchReportList();
130 buildCounterBatchReportList++; 130 buildCounterBatchReportList++;
131 if (buildCounterBatchReportList < 3) { 131 if (buildCounterBatchReportList < 3) {
132 o.items = buildUnnamed206(); 132 o.items = buildUnnamed209();
133 o.kind = "foo"; 133 o.kind = "foo";
134 } 134 }
135 buildCounterBatchReportList--; 135 buildCounterBatchReportList--;
136 return o; 136 return o;
137 } 137 }
138 138
139 checkBatchReportList(api.BatchReportList o) { 139 checkBatchReportList(api.BatchReportList o) {
140 buildCounterBatchReportList++; 140 buildCounterBatchReportList++;
141 if (buildCounterBatchReportList < 3) { 141 if (buildCounterBatchReportList < 3) {
142 checkUnnamed206(o.items); 142 checkUnnamed209(o.items);
143 unittest.expect(o.kind, unittest.equals('foo')); 143 unittest.expect(o.kind, unittest.equals('foo'));
144 } 144 }
145 buildCounterBatchReportList--; 145 buildCounterBatchReportList--;
146 } 146 }
147 147
148 core.int buildCounterBatchReportTemplateOutputs = 0; 148 core.int buildCounterBatchReportTemplateOutputs = 0;
149 buildBatchReportTemplateOutputs() { 149 buildBatchReportTemplateOutputs() {
150 var o = new api.BatchReportTemplateOutputs(); 150 var o = new api.BatchReportTemplateOutputs();
151 buildCounterBatchReportTemplateOutputs++; 151 buildCounterBatchReportTemplateOutputs++;
152 if (buildCounterBatchReportTemplateOutputs < 3) { 152 if (buildCounterBatchReportTemplateOutputs < 3) {
153 o.downloadUrl = "foo"; 153 o.downloadUrl = "foo";
154 o.format = "foo"; 154 o.format = "foo";
155 o.type = "foo"; 155 o.type = "foo";
156 } 156 }
157 buildCounterBatchReportTemplateOutputs--; 157 buildCounterBatchReportTemplateOutputs--;
158 return o; 158 return o;
159 } 159 }
160 160
161 checkBatchReportTemplateOutputs(api.BatchReportTemplateOutputs o) { 161 checkBatchReportTemplateOutputs(api.BatchReportTemplateOutputs o) {
162 buildCounterBatchReportTemplateOutputs++; 162 buildCounterBatchReportTemplateOutputs++;
163 if (buildCounterBatchReportTemplateOutputs < 3) { 163 if (buildCounterBatchReportTemplateOutputs < 3) {
164 unittest.expect(o.downloadUrl, unittest.equals('foo')); 164 unittest.expect(o.downloadUrl, unittest.equals('foo'));
165 unittest.expect(o.format, unittest.equals('foo')); 165 unittest.expect(o.format, unittest.equals('foo'));
166 unittest.expect(o.type, unittest.equals('foo')); 166 unittest.expect(o.type, unittest.equals('foo'));
167 } 167 }
168 buildCounterBatchReportTemplateOutputs--; 168 buildCounterBatchReportTemplateOutputs--;
169 } 169 }
170 170
171 buildUnnamed207() { 171 buildUnnamed210() {
172 var o = new core.List<api.BatchReportTemplateOutputs>(); 172 var o = new core.List<api.BatchReportTemplateOutputs>();
173 o.add(buildBatchReportTemplateOutputs()); 173 o.add(buildBatchReportTemplateOutputs());
174 o.add(buildBatchReportTemplateOutputs()); 174 o.add(buildBatchReportTemplateOutputs());
175 return o; 175 return o;
176 } 176 }
177 177
178 checkUnnamed207(core.List<api.BatchReportTemplateOutputs> o) { 178 checkUnnamed210(core.List<api.BatchReportTemplateOutputs> o) {
179 unittest.expect(o, unittest.hasLength(2)); 179 unittest.expect(o, unittest.hasLength(2));
180 checkBatchReportTemplateOutputs(o[0]); 180 checkBatchReportTemplateOutputs(o[0]);
181 checkBatchReportTemplateOutputs(o[1]); 181 checkBatchReportTemplateOutputs(o[1]);
182 } 182 }
183 183
184 core.int buildCounterBatchReportTemplateTimeSpan = 0; 184 core.int buildCounterBatchReportTemplateTimeSpan = 0;
185 buildBatchReportTemplateTimeSpan() { 185 buildBatchReportTemplateTimeSpan() {
186 var o = new api.BatchReportTemplateTimeSpan(); 186 var o = new api.BatchReportTemplateTimeSpan();
187 buildCounterBatchReportTemplateTimeSpan++; 187 buildCounterBatchReportTemplateTimeSpan++;
188 if (buildCounterBatchReportTemplateTimeSpan < 3) { 188 if (buildCounterBatchReportTemplateTimeSpan < 3) {
(...skipping 12 matching lines...) Expand all
201 } 201 }
202 buildCounterBatchReportTemplateTimeSpan--; 202 buildCounterBatchReportTemplateTimeSpan--;
203 } 203 }
204 204
205 core.int buildCounterBatchReportTemplate = 0; 205 core.int buildCounterBatchReportTemplate = 0;
206 buildBatchReportTemplate() { 206 buildBatchReportTemplate() {
207 var o = new api.BatchReportTemplate(); 207 var o = new api.BatchReportTemplate();
208 buildCounterBatchReportTemplate++; 208 buildCounterBatchReportTemplate++;
209 if (buildCounterBatchReportTemplate < 3) { 209 if (buildCounterBatchReportTemplate < 3) {
210 o.id = "foo"; 210 o.id = "foo";
211 o.outputs = buildUnnamed207(); 211 o.outputs = buildUnnamed210();
212 o.reportId = "foo"; 212 o.reportId = "foo";
213 o.timeSpan = buildBatchReportTemplateTimeSpan(); 213 o.timeSpan = buildBatchReportTemplateTimeSpan();
214 o.timeUpdated = core.DateTime.parse("2002-02-27T14:01:02"); 214 o.timeUpdated = core.DateTime.parse("2002-02-27T14:01:02");
215 } 215 }
216 buildCounterBatchReportTemplate--; 216 buildCounterBatchReportTemplate--;
217 return o; 217 return o;
218 } 218 }
219 219
220 checkBatchReportTemplate(api.BatchReportTemplate o) { 220 checkBatchReportTemplate(api.BatchReportTemplate o) {
221 buildCounterBatchReportTemplate++; 221 buildCounterBatchReportTemplate++;
222 if (buildCounterBatchReportTemplate < 3) { 222 if (buildCounterBatchReportTemplate < 3) {
223 unittest.expect(o.id, unittest.equals('foo')); 223 unittest.expect(o.id, unittest.equals('foo'));
224 checkUnnamed207(o.outputs); 224 checkUnnamed210(o.outputs);
225 unittest.expect(o.reportId, unittest.equals('foo')); 225 unittest.expect(o.reportId, unittest.equals('foo'));
226 checkBatchReportTemplateTimeSpan(o.timeSpan); 226 checkBatchReportTemplateTimeSpan(o.timeSpan);
227 unittest.expect(o.timeUpdated, unittest.equals(core.DateTime.parse("2002-02- 27T14:01:02"))); 227 unittest.expect(o.timeUpdated, unittest.equals(core.DateTime.parse("2002-02- 27T14:01:02")));
228 } 228 }
229 buildCounterBatchReportTemplate--; 229 buildCounterBatchReportTemplate--;
230 } 230 }
231 231
232 core.int buildCounterResultTableColumnHeaders = 0; 232 core.int buildCounterResultTableColumnHeaders = 0;
233 buildResultTableColumnHeaders() { 233 buildResultTableColumnHeaders() {
234 var o = new api.ResultTableColumnHeaders(); 234 var o = new api.ResultTableColumnHeaders();
(...skipping 10 matching lines...) Expand all
245 checkResultTableColumnHeaders(api.ResultTableColumnHeaders o) { 245 checkResultTableColumnHeaders(api.ResultTableColumnHeaders o) {
246 buildCounterResultTableColumnHeaders++; 246 buildCounterResultTableColumnHeaders++;
247 if (buildCounterResultTableColumnHeaders < 3) { 247 if (buildCounterResultTableColumnHeaders < 3) {
248 unittest.expect(o.columnType, unittest.equals('foo')); 248 unittest.expect(o.columnType, unittest.equals('foo'));
249 unittest.expect(o.dataType, unittest.equals('foo')); 249 unittest.expect(o.dataType, unittest.equals('foo'));
250 unittest.expect(o.name, unittest.equals('foo')); 250 unittest.expect(o.name, unittest.equals('foo'));
251 } 251 }
252 buildCounterResultTableColumnHeaders--; 252 buildCounterResultTableColumnHeaders--;
253 } 253 }
254 254
255 buildUnnamed208() { 255 buildUnnamed211() {
256 var o = new core.List<api.ResultTableColumnHeaders>(); 256 var o = new core.List<api.ResultTableColumnHeaders>();
257 o.add(buildResultTableColumnHeaders()); 257 o.add(buildResultTableColumnHeaders());
258 o.add(buildResultTableColumnHeaders()); 258 o.add(buildResultTableColumnHeaders());
259 return o; 259 return o;
260 } 260 }
261 261
262 checkUnnamed208(core.List<api.ResultTableColumnHeaders> o) { 262 checkUnnamed211(core.List<api.ResultTableColumnHeaders> o) {
263 unittest.expect(o, unittest.hasLength(2)); 263 unittest.expect(o, unittest.hasLength(2));
264 checkResultTableColumnHeaders(o[0]); 264 checkResultTableColumnHeaders(o[0]);
265 checkResultTableColumnHeaders(o[1]); 265 checkResultTableColumnHeaders(o[1]);
266 } 266 }
267 267
268 buildUnnamed209() { 268 buildUnnamed212() {
269 var o = new core.List<core.Object>(); 269 var o = new core.List<core.Object>();
270 o.add({'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}); 270 o.add({'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'});
271 o.add({'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}); 271 o.add({'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'});
272 return o; 272 return o;
273 } 273 }
274 274
275 checkUnnamed209(core.List<core.Object> o) { 275 checkUnnamed212(core.List<core.Object> o) {
276 unittest.expect(o, unittest.hasLength(2)); 276 unittest.expect(o, unittest.hasLength(2));
277 var casted1 = (o[0]) as core.Map; unittest.expect(casted1, unittest.hasLength( 3)); unittest.expect(casted1["list"], unittest.equals([1, 2, 3])); unittest.expe ct(casted1["bool"], unittest.equals(true)); unittest.expect(casted1["string"], u nittest.equals('foo')); 277 var casted1 = (o[0]) as core.Map; unittest.expect(casted1, unittest.hasLength( 3)); unittest.expect(casted1["list"], unittest.equals([1, 2, 3])); unittest.expe ct(casted1["bool"], unittest.equals(true)); unittest.expect(casted1["string"], u nittest.equals('foo'));
278 var casted2 = (o[1]) as core.Map; unittest.expect(casted2, unittest.hasLength( 3)); unittest.expect(casted2["list"], unittest.equals([1, 2, 3])); unittest.expe ct(casted2["bool"], unittest.equals(true)); unittest.expect(casted2["string"], u nittest.equals('foo')); 278 var casted2 = (o[1]) as core.Map; unittest.expect(casted2, unittest.hasLength( 3)); unittest.expect(casted2["list"], unittest.equals([1, 2, 3])); unittest.expe ct(casted2["bool"], unittest.equals(true)); unittest.expect(casted2["string"], u nittest.equals('foo'));
279 } 279 }
280 280
281 buildUnnamed210() { 281 buildUnnamed213() {
282 var o = new core.List<core.List<core.Object>>(); 282 var o = new core.List<core.List<core.Object>>();
283 o.add(buildUnnamed209()); 283 o.add(buildUnnamed212());
284 o.add(buildUnnamed209()); 284 o.add(buildUnnamed212());
285 return o; 285 return o;
286 } 286 }
287 287
288 checkUnnamed210(core.List<core.List<core.Object>> o) { 288 checkUnnamed213(core.List<core.List<core.Object>> o) {
289 unittest.expect(o, unittest.hasLength(2)); 289 unittest.expect(o, unittest.hasLength(2));
290 checkUnnamed209(o[0]); 290 checkUnnamed212(o[0]);
291 checkUnnamed209(o[1]); 291 checkUnnamed212(o[1]);
292 } 292 }
293 293
294 core.int buildCounterResultTable = 0; 294 core.int buildCounterResultTable = 0;
295 buildResultTable() { 295 buildResultTable() {
296 var o = new api.ResultTable(); 296 var o = new api.ResultTable();
297 buildCounterResultTable++; 297 buildCounterResultTable++;
298 if (buildCounterResultTable < 3) { 298 if (buildCounterResultTable < 3) {
299 o.columnHeaders = buildUnnamed208(); 299 o.columnHeaders = buildUnnamed211();
300 o.kind = "foo"; 300 o.kind = "foo";
301 o.rows = buildUnnamed210(); 301 o.rows = buildUnnamed213();
302 } 302 }
303 buildCounterResultTable--; 303 buildCounterResultTable--;
304 return o; 304 return o;
305 } 305 }
306 306
307 checkResultTable(api.ResultTable o) { 307 checkResultTable(api.ResultTable o) {
308 buildCounterResultTable++; 308 buildCounterResultTable++;
309 if (buildCounterResultTable < 3) { 309 if (buildCounterResultTable < 3) {
310 checkUnnamed208(o.columnHeaders); 310 checkUnnamed211(o.columnHeaders);
311 unittest.expect(o.kind, unittest.equals('foo')); 311 unittest.expect(o.kind, unittest.equals('foo'));
312 checkUnnamed210(o.rows); 312 checkUnnamed213(o.rows);
313 } 313 }
314 buildCounterResultTable--; 314 buildCounterResultTable--;
315 } 315 }
316 316
317 317
318 main() { 318 main() {
319 unittest.group("obj-schema-BatchReportDefinitionList", () { 319 unittest.group("obj-schema-BatchReportDefinitionList", () {
320 unittest.test("to-json--from-json", () { 320 unittest.test("to-json--from-json", () {
321 var o = buildBatchReportDefinitionList(); 321 var o = buildBatchReportDefinitionList();
322 var od = new api.BatchReportDefinitionList.fromJson(o.toJson()); 322 var od = new api.BatchReportDefinitionList.fromJson(o.toJson());
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
401 unittest.test("method--list", () { 401 unittest.test("method--list", () {
402 402
403 var mock = new common_test.HttpServerMock(); 403 var mock = new common_test.HttpServerMock();
404 api.BatchReportDefinitionsResourceApi res = new api.YoutubeAnalyticsApi(mo ck).batchReportDefinitions; 404 api.BatchReportDefinitionsResourceApi res = new api.YoutubeAnalyticsApi(mo ck).batchReportDefinitions;
405 var arg_onBehalfOfContentOwner = "foo"; 405 var arg_onBehalfOfContentOwner = "foo";
406 mock.register(unittest.expectAsync((http.BaseRequest req, json) { 406 mock.register(unittest.expectAsync((http.BaseRequest req, json) {
407 var path = (req.url).path; 407 var path = (req.url).path;
408 var pathOffset = 0; 408 var pathOffset = 0;
409 var index; 409 var index;
410 var subPart; 410 var subPart;
411 unittest.expect(path.substring(pathOffset, pathOffset + 22), unittest.eq uals("/youtube/analytics/v1/")); 411 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ als("/"));
412 pathOffset += 22; 412 pathOffset += 1;
413 unittest.expect(path.substring(pathOffset, pathOffset + 21), unittest.eq uals("youtube/analytics/v1/"));
414 pathOffset += 21;
413 unittest.expect(path.substring(pathOffset, pathOffset + 22), unittest.eq uals("batchReportDefinitions")); 415 unittest.expect(path.substring(pathOffset, pathOffset + 22), unittest.eq uals("batchReportDefinitions"));
414 pathOffset += 22; 416 pathOffset += 22;
415 417
416 var query = (req.url).query; 418 var query = (req.url).query;
417 var queryOffset = 0; 419 var queryOffset = 0;
418 var queryMap = {}; 420 var queryMap = {};
419 addQueryParam(n, v) => queryMap.putIfAbsent(n, () => []).add(v); 421 addQueryParam(n, v) => queryMap.putIfAbsent(n, () => []).add(v);
420 parseBool(n) { 422 parseBool(n) {
421 if (n == "true") return true; 423 if (n == "true") return true;
422 if (n == "false") return false; 424 if (n == "false") return false;
(...skipping 28 matching lines...) Expand all
451 453
452 var mock = new common_test.HttpServerMock(); 454 var mock = new common_test.HttpServerMock();
453 api.BatchReportsResourceApi res = new api.YoutubeAnalyticsApi(mock).batchR eports; 455 api.BatchReportsResourceApi res = new api.YoutubeAnalyticsApi(mock).batchR eports;
454 var arg_batchReportDefinitionId = "foo"; 456 var arg_batchReportDefinitionId = "foo";
455 var arg_onBehalfOfContentOwner = "foo"; 457 var arg_onBehalfOfContentOwner = "foo";
456 mock.register(unittest.expectAsync((http.BaseRequest req, json) { 458 mock.register(unittest.expectAsync((http.BaseRequest req, json) {
457 var path = (req.url).path; 459 var path = (req.url).path;
458 var pathOffset = 0; 460 var pathOffset = 0;
459 var index; 461 var index;
460 var subPart; 462 var subPart;
461 unittest.expect(path.substring(pathOffset, pathOffset + 22), unittest.eq uals("/youtube/analytics/v1/")); 463 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ als("/"));
462 pathOffset += 22; 464 pathOffset += 1;
465 unittest.expect(path.substring(pathOffset, pathOffset + 21), unittest.eq uals("youtube/analytics/v1/"));
466 pathOffset += 21;
463 unittest.expect(path.substring(pathOffset, pathOffset + 12), unittest.eq uals("batchReports")); 467 unittest.expect(path.substring(pathOffset, pathOffset + 12), unittest.eq uals("batchReports"));
464 pathOffset += 12; 468 pathOffset += 12;
465 469
466 var query = (req.url).query; 470 var query = (req.url).query;
467 var queryOffset = 0; 471 var queryOffset = 0;
468 var queryMap = {}; 472 var queryMap = {};
469 addQueryParam(n, v) => queryMap.putIfAbsent(n, () => []).add(v); 473 addQueryParam(n, v) => queryMap.putIfAbsent(n, () => []).add(v);
470 parseBool(n) { 474 parseBool(n) {
471 if (n == "true") return true; 475 if (n == "true") return true;
472 if (n == "false") return false; 476 if (n == "false") return false;
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
509 var arg_dimensions = "foo"; 513 var arg_dimensions = "foo";
510 var arg_filters = "foo"; 514 var arg_filters = "foo";
511 var arg_max_results = 42; 515 var arg_max_results = 42;
512 var arg_sort = "foo"; 516 var arg_sort = "foo";
513 var arg_start_index = 42; 517 var arg_start_index = 42;
514 mock.register(unittest.expectAsync((http.BaseRequest req, json) { 518 mock.register(unittest.expectAsync((http.BaseRequest req, json) {
515 var path = (req.url).path; 519 var path = (req.url).path;
516 var pathOffset = 0; 520 var pathOffset = 0;
517 var index; 521 var index;
518 var subPart; 522 var subPart;
519 unittest.expect(path.substring(pathOffset, pathOffset + 22), unittest.eq uals("/youtube/analytics/v1/")); 523 unittest.expect(path.substring(pathOffset, pathOffset + 1), unittest.equ als("/"));
520 pathOffset += 22; 524 pathOffset += 1;
525 unittest.expect(path.substring(pathOffset, pathOffset + 21), unittest.eq uals("youtube/analytics/v1/"));
526 pathOffset += 21;
521 unittest.expect(path.substring(pathOffset, pathOffset + 7), unittest.equ als("reports")); 527 unittest.expect(path.substring(pathOffset, pathOffset + 7), unittest.equ als("reports"));
522 pathOffset += 7; 528 pathOffset += 7;
523 529
524 var query = (req.url).query; 530 var query = (req.url).query;
525 var queryOffset = 0; 531 var queryOffset = 0;
526 var queryMap = {}; 532 var queryMap = {};
527 addQueryParam(n, v) => queryMap.putIfAbsent(n, () => []).add(v); 533 addQueryParam(n, v) => queryMap.putIfAbsent(n, () => []).add(v);
528 parseBool(n) { 534 parseBool(n) {
529 if (n == "true") return true; 535 if (n == "true") return true;
530 if (n == "false") return false; 536 if (n == "false") return false;
(...skipping 26 matching lines...) Expand all
557 res.query(arg_ids, arg_start_date, arg_end_date, arg_metrics, dimensions: arg_dimensions, filters: arg_filters, max_results: arg_max_results, sort: arg_so rt, start_index: arg_start_index).then(unittest.expectAsync(((api.ResultTable re sponse) { 563 res.query(arg_ids, arg_start_date, arg_end_date, arg_metrics, dimensions: arg_dimensions, filters: arg_filters, max_results: arg_max_results, sort: arg_so rt, start_index: arg_start_index).then(unittest.expectAsync(((api.ResultTable re sponse) {
558 checkResultTable(response); 564 checkResultTable(response);
559 }))); 565 })));
560 }); 566 });
561 567
562 }); 568 });
563 569
564 570
565 } 571 }
566 572
OLDNEW
« no previous file with comments | « generated/googleapis/test/youtube/v3_test.dart ('k') | generated/googleapis_beta/CHANGELOG.md » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698