OLD | NEW |
1 library googleapis.gamesManagement.v1management.test; | 1 library googleapis.gamesManagement.v1management.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/gamesmanagement/v1management.dart' as api; | 15 import 'package:googleapis/gamesmanagement/v1management.dart' as api; |
16 | 16 |
17 | 17 |
18 | 18 |
19 buildUnnamed456() { | 19 buildUnnamed75() { |
20 var o = new core.List<api.AchievementResetResponse>(); | 20 var o = new core.List<api.AchievementResetResponse>(); |
21 o.add(buildAchievementResetResponse()); | 21 o.add(buildAchievementResetResponse()); |
22 o.add(buildAchievementResetResponse()); | 22 o.add(buildAchievementResetResponse()); |
23 return o; | 23 return o; |
24 } | 24 } |
25 | 25 |
26 checkUnnamed456(core.List<api.AchievementResetResponse> o) { | 26 checkUnnamed75(core.List<api.AchievementResetResponse> o) { |
27 unittest.expect(o, unittest.hasLength(2)); | 27 unittest.expect(o, unittest.hasLength(2)); |
28 checkAchievementResetResponse(o[0]); | 28 checkAchievementResetResponse(o[0]); |
29 checkAchievementResetResponse(o[1]); | 29 checkAchievementResetResponse(o[1]); |
30 } | 30 } |
31 | 31 |
32 core.int buildCounterAchievementResetAllResponse = 0; | 32 core.int buildCounterAchievementResetAllResponse = 0; |
33 buildAchievementResetAllResponse() { | 33 buildAchievementResetAllResponse() { |
34 var o = new api.AchievementResetAllResponse(); | 34 var o = new api.AchievementResetAllResponse(); |
35 buildCounterAchievementResetAllResponse++; | 35 buildCounterAchievementResetAllResponse++; |
36 if (buildCounterAchievementResetAllResponse < 3) { | 36 if (buildCounterAchievementResetAllResponse < 3) { |
37 o.kind = "foo"; | 37 o.kind = "foo"; |
38 o.results = buildUnnamed456(); | 38 o.results = buildUnnamed75(); |
39 } | 39 } |
40 buildCounterAchievementResetAllResponse--; | 40 buildCounterAchievementResetAllResponse--; |
41 return o; | 41 return o; |
42 } | 42 } |
43 | 43 |
44 checkAchievementResetAllResponse(api.AchievementResetAllResponse o) { | 44 checkAchievementResetAllResponse(api.AchievementResetAllResponse o) { |
45 buildCounterAchievementResetAllResponse++; | 45 buildCounterAchievementResetAllResponse++; |
46 if (buildCounterAchievementResetAllResponse < 3) { | 46 if (buildCounterAchievementResetAllResponse < 3) { |
47 unittest.expect(o.kind, unittest.equals('foo')); | 47 unittest.expect(o.kind, unittest.equals('foo')); |
48 checkUnnamed456(o.results); | 48 checkUnnamed75(o.results); |
49 } | 49 } |
50 buildCounterAchievementResetAllResponse--; | 50 buildCounterAchievementResetAllResponse--; |
51 } | 51 } |
52 | 52 |
53 core.int buildCounterAchievementResetResponse = 0; | 53 core.int buildCounterAchievementResetResponse = 0; |
54 buildAchievementResetResponse() { | 54 buildAchievementResetResponse() { |
55 var o = new api.AchievementResetResponse(); | 55 var o = new api.AchievementResetResponse(); |
56 buildCounterAchievementResetResponse++; | 56 buildCounterAchievementResetResponse++; |
57 if (buildCounterAchievementResetResponse < 3) { | 57 if (buildCounterAchievementResetResponse < 3) { |
58 o.currentState = "foo"; | 58 o.currentState = "foo"; |
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
160 checkHiddenPlayer(api.HiddenPlayer o) { | 160 checkHiddenPlayer(api.HiddenPlayer o) { |
161 buildCounterHiddenPlayer++; | 161 buildCounterHiddenPlayer++; |
162 if (buildCounterHiddenPlayer < 3) { | 162 if (buildCounterHiddenPlayer < 3) { |
163 unittest.expect(o.hiddenTimeMillis, unittest.equals('foo')); | 163 unittest.expect(o.hiddenTimeMillis, unittest.equals('foo')); |
164 unittest.expect(o.kind, unittest.equals('foo')); | 164 unittest.expect(o.kind, unittest.equals('foo')); |
165 checkPlayer(o.player); | 165 checkPlayer(o.player); |
166 } | 166 } |
167 buildCounterHiddenPlayer--; | 167 buildCounterHiddenPlayer--; |
168 } | 168 } |
169 | 169 |
170 buildUnnamed457() { | 170 buildUnnamed76() { |
171 var o = new core.List<api.HiddenPlayer>(); | 171 var o = new core.List<api.HiddenPlayer>(); |
172 o.add(buildHiddenPlayer()); | 172 o.add(buildHiddenPlayer()); |
173 o.add(buildHiddenPlayer()); | 173 o.add(buildHiddenPlayer()); |
174 return o; | 174 return o; |
175 } | 175 } |
176 | 176 |
177 checkUnnamed457(core.List<api.HiddenPlayer> o) { | 177 checkUnnamed76(core.List<api.HiddenPlayer> o) { |
178 unittest.expect(o, unittest.hasLength(2)); | 178 unittest.expect(o, unittest.hasLength(2)); |
179 checkHiddenPlayer(o[0]); | 179 checkHiddenPlayer(o[0]); |
180 checkHiddenPlayer(o[1]); | 180 checkHiddenPlayer(o[1]); |
181 } | 181 } |
182 | 182 |
183 core.int buildCounterHiddenPlayerList = 0; | 183 core.int buildCounterHiddenPlayerList = 0; |
184 buildHiddenPlayerList() { | 184 buildHiddenPlayerList() { |
185 var o = new api.HiddenPlayerList(); | 185 var o = new api.HiddenPlayerList(); |
186 buildCounterHiddenPlayerList++; | 186 buildCounterHiddenPlayerList++; |
187 if (buildCounterHiddenPlayerList < 3) { | 187 if (buildCounterHiddenPlayerList < 3) { |
188 o.items = buildUnnamed457(); | 188 o.items = buildUnnamed76(); |
189 o.kind = "foo"; | 189 o.kind = "foo"; |
190 o.nextPageToken = "foo"; | 190 o.nextPageToken = "foo"; |
191 } | 191 } |
192 buildCounterHiddenPlayerList--; | 192 buildCounterHiddenPlayerList--; |
193 return o; | 193 return o; |
194 } | 194 } |
195 | 195 |
196 checkHiddenPlayerList(api.HiddenPlayerList o) { | 196 checkHiddenPlayerList(api.HiddenPlayerList o) { |
197 buildCounterHiddenPlayerList++; | 197 buildCounterHiddenPlayerList++; |
198 if (buildCounterHiddenPlayerList < 3) { | 198 if (buildCounterHiddenPlayerList < 3) { |
199 checkUnnamed457(o.items); | 199 checkUnnamed76(o.items); |
200 unittest.expect(o.kind, unittest.equals('foo')); | 200 unittest.expect(o.kind, unittest.equals('foo')); |
201 unittest.expect(o.nextPageToken, unittest.equals('foo')); | 201 unittest.expect(o.nextPageToken, unittest.equals('foo')); |
202 } | 202 } |
203 buildCounterHiddenPlayerList--; | 203 buildCounterHiddenPlayerList--; |
204 } | 204 } |
205 | 205 |
206 core.int buildCounterPlayerName = 0; | 206 core.int buildCounterPlayerName = 0; |
207 buildPlayerName() { | 207 buildPlayerName() { |
208 var o = new api.PlayerName(); | 208 var o = new api.PlayerName(); |
209 buildCounterPlayerName++; | 209 buildCounterPlayerName++; |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
250 checkGamesPlayerExperienceInfoResource(o.experienceInfo); | 250 checkGamesPlayerExperienceInfoResource(o.experienceInfo); |
251 unittest.expect(o.kind, unittest.equals('foo')); | 251 unittest.expect(o.kind, unittest.equals('foo')); |
252 checkGamesPlayedResource(o.lastPlayedWith); | 252 checkGamesPlayedResource(o.lastPlayedWith); |
253 checkPlayerName(o.name); | 253 checkPlayerName(o.name); |
254 unittest.expect(o.playerId, unittest.equals('foo')); | 254 unittest.expect(o.playerId, unittest.equals('foo')); |
255 unittest.expect(o.title, unittest.equals('foo')); | 255 unittest.expect(o.title, unittest.equals('foo')); |
256 } | 256 } |
257 buildCounterPlayer--; | 257 buildCounterPlayer--; |
258 } | 258 } |
259 | 259 |
260 buildUnnamed458() { | 260 buildUnnamed77() { |
261 var o = new core.List<core.String>(); | 261 var o = new core.List<core.String>(); |
262 o.add("foo"); | 262 o.add("foo"); |
263 o.add("foo"); | 263 o.add("foo"); |
264 return o; | 264 return o; |
265 } | 265 } |
266 | 266 |
267 checkUnnamed458(core.List<core.String> o) { | 267 checkUnnamed77(core.List<core.String> o) { |
268 unittest.expect(o, unittest.hasLength(2)); | 268 unittest.expect(o, unittest.hasLength(2)); |
269 unittest.expect(o[0], unittest.equals('foo')); | 269 unittest.expect(o[0], unittest.equals('foo')); |
270 unittest.expect(o[1], unittest.equals('foo')); | 270 unittest.expect(o[1], unittest.equals('foo')); |
271 } | 271 } |
272 | 272 |
273 core.int buildCounterPlayerScoreResetResponse = 0; | 273 core.int buildCounterPlayerScoreResetResponse = 0; |
274 buildPlayerScoreResetResponse() { | 274 buildPlayerScoreResetResponse() { |
275 var o = new api.PlayerScoreResetResponse(); | 275 var o = new api.PlayerScoreResetResponse(); |
276 buildCounterPlayerScoreResetResponse++; | 276 buildCounterPlayerScoreResetResponse++; |
277 if (buildCounterPlayerScoreResetResponse < 3) { | 277 if (buildCounterPlayerScoreResetResponse < 3) { |
278 o.kind = "foo"; | 278 o.kind = "foo"; |
279 o.resetScoreTimeSpans = buildUnnamed458(); | 279 o.resetScoreTimeSpans = buildUnnamed77(); |
280 } | 280 } |
281 buildCounterPlayerScoreResetResponse--; | 281 buildCounterPlayerScoreResetResponse--; |
282 return o; | 282 return o; |
283 } | 283 } |
284 | 284 |
285 checkPlayerScoreResetResponse(api.PlayerScoreResetResponse o) { | 285 checkPlayerScoreResetResponse(api.PlayerScoreResetResponse o) { |
286 buildCounterPlayerScoreResetResponse++; | 286 buildCounterPlayerScoreResetResponse++; |
287 if (buildCounterPlayerScoreResetResponse < 3) { | 287 if (buildCounterPlayerScoreResetResponse < 3) { |
288 unittest.expect(o.kind, unittest.equals('foo')); | 288 unittest.expect(o.kind, unittest.equals('foo')); |
289 checkUnnamed458(o.resetScoreTimeSpans); | 289 checkUnnamed77(o.resetScoreTimeSpans); |
290 } | 290 } |
291 buildCounterPlayerScoreResetResponse--; | 291 buildCounterPlayerScoreResetResponse--; |
292 } | 292 } |
293 | 293 |
294 | 294 |
295 main() { | 295 main() { |
296 unittest.group("obj-schema-AchievementResetAllResponse", () { | 296 unittest.group("obj-schema-AchievementResetAllResponse", () { |
297 unittest.test("to-json--from-json", () { | 297 unittest.test("to-json--from-json", () { |
298 var o = buildAchievementResetAllResponse(); | 298 var o = buildAchievementResetAllResponse(); |
299 var od = new api.AchievementResetAllResponse.fromJson(o.toJson()); | 299 var od = new api.AchievementResetAllResponse.fromJson(o.toJson()); |
(...skipping 812 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1112 return new async.Future.value(common_test.stringResponse(200, h, resp)); | 1112 return new async.Future.value(common_test.stringResponse(200, h, resp)); |
1113 }), true); | 1113 }), true); |
1114 res.reset().then(unittest.expectAsync((_) {})); | 1114 res.reset().then(unittest.expectAsync((_) {})); |
1115 }); | 1115 }); |
1116 | 1116 |
1117 }); | 1117 }); |
1118 | 1118 |
1119 | 1119 |
1120 } | 1120 } |
1121 | 1121 |
OLD | NEW |