| OLD | NEW |
| 1 library googleapis.customsearch.v1.test; | 1 library googleapis.customsearch.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:test/test.dart' as unittest; | 10 import 'package:test/test.dart' as unittest; |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 67 checkContextFacets(api.ContextFacets o) { | 67 checkContextFacets(api.ContextFacets o) { |
| 68 buildCounterContextFacets++; | 68 buildCounterContextFacets++; |
| 69 if (buildCounterContextFacets < 3) { | 69 if (buildCounterContextFacets < 3) { |
| 70 unittest.expect(o.anchor, unittest.equals('foo')); | 70 unittest.expect(o.anchor, unittest.equals('foo')); |
| 71 unittest.expect(o.label, unittest.equals('foo')); | 71 unittest.expect(o.label, unittest.equals('foo')); |
| 72 unittest.expect(o.labelWithOp, unittest.equals('foo')); | 72 unittest.expect(o.labelWithOp, unittest.equals('foo')); |
| 73 } | 73 } |
| 74 buildCounterContextFacets--; | 74 buildCounterContextFacets--; |
| 75 } | 75 } |
| 76 | 76 |
| 77 buildUnnamed244() { | 77 buildUnnamed319() { |
| 78 var o = new core.List<api.ContextFacets>(); | 78 var o = new core.List<api.ContextFacets>(); |
| 79 o.add(buildContextFacets()); | 79 o.add(buildContextFacets()); |
| 80 o.add(buildContextFacets()); | 80 o.add(buildContextFacets()); |
| 81 return o; | 81 return o; |
| 82 } | 82 } |
| 83 | 83 |
| 84 checkUnnamed244(core.List<api.ContextFacets> o) { | 84 checkUnnamed319(core.List<api.ContextFacets> o) { |
| 85 unittest.expect(o, unittest.hasLength(2)); | 85 unittest.expect(o, unittest.hasLength(2)); |
| 86 checkContextFacets(o[0]); | 86 checkContextFacets(o[0]); |
| 87 checkContextFacets(o[1]); | 87 checkContextFacets(o[1]); |
| 88 } | 88 } |
| 89 | 89 |
| 90 buildUnnamed245() { | 90 buildUnnamed320() { |
| 91 var o = new core.List<core.List<api.ContextFacets>>(); | 91 var o = new core.List<core.List<api.ContextFacets>>(); |
| 92 o.add(buildUnnamed244()); | 92 o.add(buildUnnamed319()); |
| 93 o.add(buildUnnamed244()); | 93 o.add(buildUnnamed319()); |
| 94 return o; | 94 return o; |
| 95 } | 95 } |
| 96 | 96 |
| 97 checkUnnamed245(core.List<core.List<api.ContextFacets>> o) { | 97 checkUnnamed320(core.List<core.List<api.ContextFacets>> o) { |
| 98 unittest.expect(o, unittest.hasLength(2)); | 98 unittest.expect(o, unittest.hasLength(2)); |
| 99 checkUnnamed244(o[0]); | 99 checkUnnamed319(o[0]); |
| 100 checkUnnamed244(o[1]); | 100 checkUnnamed319(o[1]); |
| 101 } | 101 } |
| 102 | 102 |
| 103 core.int buildCounterContext = 0; | 103 core.int buildCounterContext = 0; |
| 104 buildContext() { | 104 buildContext() { |
| 105 var o = new api.Context(); | 105 var o = new api.Context(); |
| 106 buildCounterContext++; | 106 buildCounterContext++; |
| 107 if (buildCounterContext < 3) { | 107 if (buildCounterContext < 3) { |
| 108 o.facets = buildUnnamed245(); | 108 o.facets = buildUnnamed320(); |
| 109 o.title = "foo"; | 109 o.title = "foo"; |
| 110 } | 110 } |
| 111 buildCounterContext--; | 111 buildCounterContext--; |
| 112 return o; | 112 return o; |
| 113 } | 113 } |
| 114 | 114 |
| 115 checkContext(api.Context o) { | 115 checkContext(api.Context o) { |
| 116 buildCounterContext++; | 116 buildCounterContext++; |
| 117 if (buildCounterContext < 3) { | 117 if (buildCounterContext < 3) { |
| 118 checkUnnamed245(o.facets); | 118 checkUnnamed320(o.facets); |
| 119 unittest.expect(o.title, unittest.equals('foo')); | 119 unittest.expect(o.title, unittest.equals('foo')); |
| 120 } | 120 } |
| 121 buildCounterContext--; | 121 buildCounterContext--; |
| 122 } | 122 } |
| 123 | 123 |
| 124 core.int buildCounterPromotionBodyLines = 0; | 124 core.int buildCounterPromotionBodyLines = 0; |
| 125 buildPromotionBodyLines() { | 125 buildPromotionBodyLines() { |
| 126 var o = new api.PromotionBodyLines(); | 126 var o = new api.PromotionBodyLines(); |
| 127 buildCounterPromotionBodyLines++; | 127 buildCounterPromotionBodyLines++; |
| 128 if (buildCounterPromotionBodyLines < 3) { | 128 if (buildCounterPromotionBodyLines < 3) { |
| (...skipping 10 matching lines...) Expand all Loading... |
| 139 buildCounterPromotionBodyLines++; | 139 buildCounterPromotionBodyLines++; |
| 140 if (buildCounterPromotionBodyLines < 3) { | 140 if (buildCounterPromotionBodyLines < 3) { |
| 141 unittest.expect(o.htmlTitle, unittest.equals('foo')); | 141 unittest.expect(o.htmlTitle, unittest.equals('foo')); |
| 142 unittest.expect(o.link, unittest.equals('foo')); | 142 unittest.expect(o.link, unittest.equals('foo')); |
| 143 unittest.expect(o.title, unittest.equals('foo')); | 143 unittest.expect(o.title, unittest.equals('foo')); |
| 144 unittest.expect(o.url, unittest.equals('foo')); | 144 unittest.expect(o.url, unittest.equals('foo')); |
| 145 } | 145 } |
| 146 buildCounterPromotionBodyLines--; | 146 buildCounterPromotionBodyLines--; |
| 147 } | 147 } |
| 148 | 148 |
| 149 buildUnnamed246() { | 149 buildUnnamed321() { |
| 150 var o = new core.List<api.PromotionBodyLines>(); | 150 var o = new core.List<api.PromotionBodyLines>(); |
| 151 o.add(buildPromotionBodyLines()); | 151 o.add(buildPromotionBodyLines()); |
| 152 o.add(buildPromotionBodyLines()); | 152 o.add(buildPromotionBodyLines()); |
| 153 return o; | 153 return o; |
| 154 } | 154 } |
| 155 | 155 |
| 156 checkUnnamed246(core.List<api.PromotionBodyLines> o) { | 156 checkUnnamed321(core.List<api.PromotionBodyLines> o) { |
| 157 unittest.expect(o, unittest.hasLength(2)); | 157 unittest.expect(o, unittest.hasLength(2)); |
| 158 checkPromotionBodyLines(o[0]); | 158 checkPromotionBodyLines(o[0]); |
| 159 checkPromotionBodyLines(o[1]); | 159 checkPromotionBodyLines(o[1]); |
| 160 } | 160 } |
| 161 | 161 |
| 162 core.int buildCounterPromotionImage = 0; | 162 core.int buildCounterPromotionImage = 0; |
| 163 buildPromotionImage() { | 163 buildPromotionImage() { |
| 164 var o = new api.PromotionImage(); | 164 var o = new api.PromotionImage(); |
| 165 buildCounterPromotionImage++; | 165 buildCounterPromotionImage++; |
| 166 if (buildCounterPromotionImage < 3) { | 166 if (buildCounterPromotionImage < 3) { |
| (...skipping 13 matching lines...) Expand all Loading... |
| 180 unittest.expect(o.width, unittest.equals(42)); | 180 unittest.expect(o.width, unittest.equals(42)); |
| 181 } | 181 } |
| 182 buildCounterPromotionImage--; | 182 buildCounterPromotionImage--; |
| 183 } | 183 } |
| 184 | 184 |
| 185 core.int buildCounterPromotion = 0; | 185 core.int buildCounterPromotion = 0; |
| 186 buildPromotion() { | 186 buildPromotion() { |
| 187 var o = new api.Promotion(); | 187 var o = new api.Promotion(); |
| 188 buildCounterPromotion++; | 188 buildCounterPromotion++; |
| 189 if (buildCounterPromotion < 3) { | 189 if (buildCounterPromotion < 3) { |
| 190 o.bodyLines = buildUnnamed246(); | 190 o.bodyLines = buildUnnamed321(); |
| 191 o.displayLink = "foo"; | 191 o.displayLink = "foo"; |
| 192 o.htmlTitle = "foo"; | 192 o.htmlTitle = "foo"; |
| 193 o.image = buildPromotionImage(); | 193 o.image = buildPromotionImage(); |
| 194 o.link = "foo"; | 194 o.link = "foo"; |
| 195 o.title = "foo"; | 195 o.title = "foo"; |
| 196 } | 196 } |
| 197 buildCounterPromotion--; | 197 buildCounterPromotion--; |
| 198 return o; | 198 return o; |
| 199 } | 199 } |
| 200 | 200 |
| 201 checkPromotion(api.Promotion o) { | 201 checkPromotion(api.Promotion o) { |
| 202 buildCounterPromotion++; | 202 buildCounterPromotion++; |
| 203 if (buildCounterPromotion < 3) { | 203 if (buildCounterPromotion < 3) { |
| 204 checkUnnamed246(o.bodyLines); | 204 checkUnnamed321(o.bodyLines); |
| 205 unittest.expect(o.displayLink, unittest.equals('foo')); | 205 unittest.expect(o.displayLink, unittest.equals('foo')); |
| 206 unittest.expect(o.htmlTitle, unittest.equals('foo')); | 206 unittest.expect(o.htmlTitle, unittest.equals('foo')); |
| 207 checkPromotionImage(o.image); | 207 checkPromotionImage(o.image); |
| 208 unittest.expect(o.link, unittest.equals('foo')); | 208 unittest.expect(o.link, unittest.equals('foo')); |
| 209 unittest.expect(o.title, unittest.equals('foo')); | 209 unittest.expect(o.title, unittest.equals('foo')); |
| 210 } | 210 } |
| 211 buildCounterPromotion--; | 211 buildCounterPromotion--; |
| 212 } | 212 } |
| 213 | 213 |
| 214 core.int buildCounterQuery = 0; | 214 core.int buildCounterQuery = 0; |
| (...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 347 checkResultLabels(api.ResultLabels o) { | 347 checkResultLabels(api.ResultLabels o) { |
| 348 buildCounterResultLabels++; | 348 buildCounterResultLabels++; |
| 349 if (buildCounterResultLabels < 3) { | 349 if (buildCounterResultLabels < 3) { |
| 350 unittest.expect(o.displayName, unittest.equals('foo')); | 350 unittest.expect(o.displayName, unittest.equals('foo')); |
| 351 unittest.expect(o.labelWithOp, unittest.equals('foo')); | 351 unittest.expect(o.labelWithOp, unittest.equals('foo')); |
| 352 unittest.expect(o.name, unittest.equals('foo')); | 352 unittest.expect(o.name, unittest.equals('foo')); |
| 353 } | 353 } |
| 354 buildCounterResultLabels--; | 354 buildCounterResultLabels--; |
| 355 } | 355 } |
| 356 | 356 |
| 357 buildUnnamed247() { | 357 buildUnnamed322() { |
| 358 var o = new core.List<api.ResultLabels>(); | 358 var o = new core.List<api.ResultLabels>(); |
| 359 o.add(buildResultLabels()); | 359 o.add(buildResultLabels()); |
| 360 o.add(buildResultLabels()); | 360 o.add(buildResultLabels()); |
| 361 return o; | 361 return o; |
| 362 } | 362 } |
| 363 | 363 |
| 364 checkUnnamed247(core.List<api.ResultLabels> o) { | 364 checkUnnamed322(core.List<api.ResultLabels> o) { |
| 365 unittest.expect(o, unittest.hasLength(2)); | 365 unittest.expect(o, unittest.hasLength(2)); |
| 366 checkResultLabels(o[0]); | 366 checkResultLabels(o[0]); |
| 367 checkResultLabels(o[1]); | 367 checkResultLabels(o[1]); |
| 368 } | 368 } |
| 369 | 369 |
| 370 buildUnnamed248() { | 370 buildUnnamed323() { |
| 371 var o = new core.Map<core.String, core.Object>(); | 371 var o = new core.Map<core.String, core.Object>(); |
| 372 o["x"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; | 372 o["x"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; |
| 373 o["y"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; | 373 o["y"] = {'list' : [1, 2, 3], 'bool' : true, 'string' : 'foo'}; |
| 374 return o; | 374 return o; |
| 375 } | 375 } |
| 376 | 376 |
| 377 checkUnnamed248(core.Map<core.String, core.Object> o) { | 377 checkUnnamed323(core.Map<core.String, core.Object> o) { |
| 378 unittest.expect(o, unittest.hasLength(2)); | 378 unittest.expect(o, unittest.hasLength(2)); |
| 379 var casted1 = (o["x"]) as core.Map; unittest.expect(casted1, unittest.hasLengt
h(3)); unittest.expect(casted1["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted1["bool"], unittest.equals(true)); unittest.expect(casted1["string"],
unittest.equals('foo')); | 379 var casted1 = (o["x"]) as core.Map; unittest.expect(casted1, unittest.hasLengt
h(3)); unittest.expect(casted1["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted1["bool"], unittest.equals(true)); unittest.expect(casted1["string"],
unittest.equals('foo')); |
| 380 var casted2 = (o["y"]) as core.Map; unittest.expect(casted2, unittest.hasLengt
h(3)); unittest.expect(casted2["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted2["bool"], unittest.equals(true)); unittest.expect(casted2["string"],
unittest.equals('foo')); | 380 var casted2 = (o["y"]) as core.Map; unittest.expect(casted2, unittest.hasLengt
h(3)); unittest.expect(casted2["list"], unittest.equals([1, 2, 3])); unittest.ex
pect(casted2["bool"], unittest.equals(true)); unittest.expect(casted2["string"],
unittest.equals('foo')); |
| 381 } | 381 } |
| 382 | 382 |
| 383 buildUnnamed249() { | 383 buildUnnamed324() { |
| 384 var o = new core.List<core.Map<core.String, core.Object>>(); | 384 var o = new core.List<core.Map<core.String, core.Object>>(); |
| 385 o.add(buildUnnamed248()); | 385 o.add(buildUnnamed323()); |
| 386 o.add(buildUnnamed248()); | 386 o.add(buildUnnamed323()); |
| 387 return o; | 387 return o; |
| 388 } | 388 } |
| 389 | 389 |
| 390 checkUnnamed249(core.List<core.Map<core.String, core.Object>> o) { | 390 checkUnnamed324(core.List<core.Map<core.String, core.Object>> o) { |
| 391 unittest.expect(o, unittest.hasLength(2)); | 391 unittest.expect(o, unittest.hasLength(2)); |
| 392 checkUnnamed248(o[0]); | 392 checkUnnamed323(o[0]); |
| 393 checkUnnamed248(o[1]); | 393 checkUnnamed323(o[1]); |
| 394 } | 394 } |
| 395 | 395 |
| 396 buildUnnamed250() { | 396 buildUnnamed325() { |
| 397 var o = new core.Map<core.String, core.List<core.Map<core.String, core.Object>
>>(); | 397 var o = new core.Map<core.String, core.List<core.Map<core.String, core.Object>
>>(); |
| 398 o["x"] = buildUnnamed249(); | 398 o["x"] = buildUnnamed324(); |
| 399 o["y"] = buildUnnamed249(); | 399 o["y"] = buildUnnamed324(); |
| 400 return o; | 400 return o; |
| 401 } | 401 } |
| 402 | 402 |
| 403 checkUnnamed250(core.Map<core.String, core.List<core.Map<core.String, core.Objec
t>>> o) { | 403 checkUnnamed325(core.Map<core.String, core.List<core.Map<core.String, core.Objec
t>>> o) { |
| 404 unittest.expect(o, unittest.hasLength(2)); | 404 unittest.expect(o, unittest.hasLength(2)); |
| 405 checkUnnamed249(o["x"]); | 405 checkUnnamed324(o["x"]); |
| 406 checkUnnamed249(o["y"]); | 406 checkUnnamed324(o["y"]); |
| 407 } | 407 } |
| 408 | 408 |
| 409 core.int buildCounterResult = 0; | 409 core.int buildCounterResult = 0; |
| 410 buildResult() { | 410 buildResult() { |
| 411 var o = new api.Result(); | 411 var o = new api.Result(); |
| 412 buildCounterResult++; | 412 buildCounterResult++; |
| 413 if (buildCounterResult < 3) { | 413 if (buildCounterResult < 3) { |
| 414 o.cacheId = "foo"; | 414 o.cacheId = "foo"; |
| 415 o.displayLink = "foo"; | 415 o.displayLink = "foo"; |
| 416 o.fileFormat = "foo"; | 416 o.fileFormat = "foo"; |
| 417 o.formattedUrl = "foo"; | 417 o.formattedUrl = "foo"; |
| 418 o.htmlFormattedUrl = "foo"; | 418 o.htmlFormattedUrl = "foo"; |
| 419 o.htmlSnippet = "foo"; | 419 o.htmlSnippet = "foo"; |
| 420 o.htmlTitle = "foo"; | 420 o.htmlTitle = "foo"; |
| 421 o.image = buildResultImage(); | 421 o.image = buildResultImage(); |
| 422 o.kind = "foo"; | 422 o.kind = "foo"; |
| 423 o.labels = buildUnnamed247(); | 423 o.labels = buildUnnamed322(); |
| 424 o.link = "foo"; | 424 o.link = "foo"; |
| 425 o.mime = "foo"; | 425 o.mime = "foo"; |
| 426 o.pagemap = buildUnnamed250(); | 426 o.pagemap = buildUnnamed325(); |
| 427 o.snippet = "foo"; | 427 o.snippet = "foo"; |
| 428 o.title = "foo"; | 428 o.title = "foo"; |
| 429 } | 429 } |
| 430 buildCounterResult--; | 430 buildCounterResult--; |
| 431 return o; | 431 return o; |
| 432 } | 432 } |
| 433 | 433 |
| 434 checkResult(api.Result o) { | 434 checkResult(api.Result o) { |
| 435 buildCounterResult++; | 435 buildCounterResult++; |
| 436 if (buildCounterResult < 3) { | 436 if (buildCounterResult < 3) { |
| 437 unittest.expect(o.cacheId, unittest.equals('foo')); | 437 unittest.expect(o.cacheId, unittest.equals('foo')); |
| 438 unittest.expect(o.displayLink, unittest.equals('foo')); | 438 unittest.expect(o.displayLink, unittest.equals('foo')); |
| 439 unittest.expect(o.fileFormat, unittest.equals('foo')); | 439 unittest.expect(o.fileFormat, unittest.equals('foo')); |
| 440 unittest.expect(o.formattedUrl, unittest.equals('foo')); | 440 unittest.expect(o.formattedUrl, unittest.equals('foo')); |
| 441 unittest.expect(o.htmlFormattedUrl, unittest.equals('foo')); | 441 unittest.expect(o.htmlFormattedUrl, unittest.equals('foo')); |
| 442 unittest.expect(o.htmlSnippet, unittest.equals('foo')); | 442 unittest.expect(o.htmlSnippet, unittest.equals('foo')); |
| 443 unittest.expect(o.htmlTitle, unittest.equals('foo')); | 443 unittest.expect(o.htmlTitle, unittest.equals('foo')); |
| 444 checkResultImage(o.image); | 444 checkResultImage(o.image); |
| 445 unittest.expect(o.kind, unittest.equals('foo')); | 445 unittest.expect(o.kind, unittest.equals('foo')); |
| 446 checkUnnamed247(o.labels); | 446 checkUnnamed322(o.labels); |
| 447 unittest.expect(o.link, unittest.equals('foo')); | 447 unittest.expect(o.link, unittest.equals('foo')); |
| 448 unittest.expect(o.mime, unittest.equals('foo')); | 448 unittest.expect(o.mime, unittest.equals('foo')); |
| 449 checkUnnamed250(o.pagemap); | 449 checkUnnamed325(o.pagemap); |
| 450 unittest.expect(o.snippet, unittest.equals('foo')); | 450 unittest.expect(o.snippet, unittest.equals('foo')); |
| 451 unittest.expect(o.title, unittest.equals('foo')); | 451 unittest.expect(o.title, unittest.equals('foo')); |
| 452 } | 452 } |
| 453 buildCounterResult--; | 453 buildCounterResult--; |
| 454 } | 454 } |
| 455 | 455 |
| 456 buildUnnamed251() { | 456 buildUnnamed326() { |
| 457 var o = new core.List<api.Result>(); | 457 var o = new core.List<api.Result>(); |
| 458 o.add(buildResult()); | 458 o.add(buildResult()); |
| 459 o.add(buildResult()); | 459 o.add(buildResult()); |
| 460 return o; | 460 return o; |
| 461 } | 461 } |
| 462 | 462 |
| 463 checkUnnamed251(core.List<api.Result> o) { | 463 checkUnnamed326(core.List<api.Result> o) { |
| 464 unittest.expect(o, unittest.hasLength(2)); | 464 unittest.expect(o, unittest.hasLength(2)); |
| 465 checkResult(o[0]); | 465 checkResult(o[0]); |
| 466 checkResult(o[1]); | 466 checkResult(o[1]); |
| 467 } | 467 } |
| 468 | 468 |
| 469 buildUnnamed252() { | 469 buildUnnamed327() { |
| 470 var o = new core.List<api.Promotion>(); | 470 var o = new core.List<api.Promotion>(); |
| 471 o.add(buildPromotion()); | 471 o.add(buildPromotion()); |
| 472 o.add(buildPromotion()); | 472 o.add(buildPromotion()); |
| 473 return o; | 473 return o; |
| 474 } | 474 } |
| 475 | 475 |
| 476 checkUnnamed252(core.List<api.Promotion> o) { | 476 checkUnnamed327(core.List<api.Promotion> o) { |
| 477 unittest.expect(o, unittest.hasLength(2)); | 477 unittest.expect(o, unittest.hasLength(2)); |
| 478 checkPromotion(o[0]); | 478 checkPromotion(o[0]); |
| 479 checkPromotion(o[1]); | 479 checkPromotion(o[1]); |
| 480 } | 480 } |
| 481 | 481 |
| 482 buildUnnamed253() { | 482 buildUnnamed328() { |
| 483 var o = new core.List<api.Query>(); | 483 var o = new core.List<api.Query>(); |
| 484 o.add(buildQuery()); | 484 o.add(buildQuery()); |
| 485 o.add(buildQuery()); | 485 o.add(buildQuery()); |
| 486 return o; | 486 return o; |
| 487 } | 487 } |
| 488 | 488 |
| 489 checkUnnamed253(core.List<api.Query> o) { | 489 checkUnnamed328(core.List<api.Query> o) { |
| 490 unittest.expect(o, unittest.hasLength(2)); | 490 unittest.expect(o, unittest.hasLength(2)); |
| 491 checkQuery(o[0]); | 491 checkQuery(o[0]); |
| 492 checkQuery(o[1]); | 492 checkQuery(o[1]); |
| 493 } | 493 } |
| 494 | 494 |
| 495 buildUnnamed254() { | 495 buildUnnamed329() { |
| 496 var o = new core.Map<core.String, core.List<api.Query>>(); | 496 var o = new core.Map<core.String, core.List<api.Query>>(); |
| 497 o["x"] = buildUnnamed253(); | 497 o["x"] = buildUnnamed328(); |
| 498 o["y"] = buildUnnamed253(); | 498 o["y"] = buildUnnamed328(); |
| 499 return o; | 499 return o; |
| 500 } | 500 } |
| 501 | 501 |
| 502 checkUnnamed254(core.Map<core.String, core.List<api.Query>> o) { | 502 checkUnnamed329(core.Map<core.String, core.List<api.Query>> o) { |
| 503 unittest.expect(o, unittest.hasLength(2)); | 503 unittest.expect(o, unittest.hasLength(2)); |
| 504 checkUnnamed253(o["x"]); | 504 checkUnnamed328(o["x"]); |
| 505 checkUnnamed253(o["y"]); | 505 checkUnnamed328(o["y"]); |
| 506 } | 506 } |
| 507 | 507 |
| 508 core.int buildCounterSearchSearchInformation = 0; | 508 core.int buildCounterSearchSearchInformation = 0; |
| 509 buildSearchSearchInformation() { | 509 buildSearchSearchInformation() { |
| 510 var o = new api.SearchSearchInformation(); | 510 var o = new api.SearchSearchInformation(); |
| 511 buildCounterSearchSearchInformation++; | 511 buildCounterSearchSearchInformation++; |
| 512 if (buildCounterSearchSearchInformation < 3) { | 512 if (buildCounterSearchSearchInformation < 3) { |
| 513 o.formattedSearchTime = "foo"; | 513 o.formattedSearchTime = "foo"; |
| 514 o.formattedTotalResults = "foo"; | 514 o.formattedTotalResults = "foo"; |
| 515 o.searchTime = 42.0; | 515 o.searchTime = 42.0; |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 571 } | 571 } |
| 572 buildCounterSearchUrl--; | 572 buildCounterSearchUrl--; |
| 573 } | 573 } |
| 574 | 574 |
| 575 core.int buildCounterSearch = 0; | 575 core.int buildCounterSearch = 0; |
| 576 buildSearch() { | 576 buildSearch() { |
| 577 var o = new api.Search(); | 577 var o = new api.Search(); |
| 578 buildCounterSearch++; | 578 buildCounterSearch++; |
| 579 if (buildCounterSearch < 3) { | 579 if (buildCounterSearch < 3) { |
| 580 o.context = buildContext(); | 580 o.context = buildContext(); |
| 581 o.items = buildUnnamed251(); | 581 o.items = buildUnnamed326(); |
| 582 o.kind = "foo"; | 582 o.kind = "foo"; |
| 583 o.promotions = buildUnnamed252(); | 583 o.promotions = buildUnnamed327(); |
| 584 o.queries = buildUnnamed254(); | 584 o.queries = buildUnnamed329(); |
| 585 o.searchInformation = buildSearchSearchInformation(); | 585 o.searchInformation = buildSearchSearchInformation(); |
| 586 o.spelling = buildSearchSpelling(); | 586 o.spelling = buildSearchSpelling(); |
| 587 o.url = buildSearchUrl(); | 587 o.url = buildSearchUrl(); |
| 588 } | 588 } |
| 589 buildCounterSearch--; | 589 buildCounterSearch--; |
| 590 return o; | 590 return o; |
| 591 } | 591 } |
| 592 | 592 |
| 593 checkSearch(api.Search o) { | 593 checkSearch(api.Search o) { |
| 594 buildCounterSearch++; | 594 buildCounterSearch++; |
| 595 if (buildCounterSearch < 3) { | 595 if (buildCounterSearch < 3) { |
| 596 checkContext(o.context); | 596 checkContext(o.context); |
| 597 checkUnnamed251(o.items); | 597 checkUnnamed326(o.items); |
| 598 unittest.expect(o.kind, unittest.equals('foo')); | 598 unittest.expect(o.kind, unittest.equals('foo')); |
| 599 checkUnnamed252(o.promotions); | 599 checkUnnamed327(o.promotions); |
| 600 checkUnnamed254(o.queries); | 600 checkUnnamed329(o.queries); |
| 601 checkSearchSearchInformation(o.searchInformation); | 601 checkSearchSearchInformation(o.searchInformation); |
| 602 checkSearchSpelling(o.spelling); | 602 checkSearchSpelling(o.spelling); |
| 603 checkSearchUrl(o.url); | 603 checkSearchUrl(o.url); |
| 604 } | 604 } |
| 605 buildCounterSearch--; | 605 buildCounterSearch--; |
| 606 } | 606 } |
| 607 | 607 |
| 608 | 608 |
| 609 main() { | 609 main() { |
| 610 unittest.group("obj-schema-ContextFacets", () { | 610 unittest.group("obj-schema-ContextFacets", () { |
| (...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 830 res.list(arg_q, c2coff: arg_c2coff, cr: arg_cr, cx: arg_cx, dateRestrict:
arg_dateRestrict, exactTerms: arg_exactTerms, excludeTerms: arg_excludeTerms, fi
leType: arg_fileType, filter: arg_filter, gl: arg_gl, googlehost: arg_googlehost
, highRange: arg_highRange, hl: arg_hl, hq: arg_hq, imgColorType: arg_imgColorTy
pe, imgDominantColor: arg_imgDominantColor, imgSize: arg_imgSize, imgType: arg_i
mgType, linkSite: arg_linkSite, lowRange: arg_lowRange, lr: arg_lr, num: arg_num
, orTerms: arg_orTerms, relatedSite: arg_relatedSite, rights: arg_rights, safe:
arg_safe, searchType: arg_searchType, siteSearch: arg_siteSearch, siteSearchFilt
er: arg_siteSearchFilter, sort: arg_sort, start: arg_start).then(unittest.expect
Async1(((api.Search response) { | 830 res.list(arg_q, c2coff: arg_c2coff, cr: arg_cr, cx: arg_cx, dateRestrict:
arg_dateRestrict, exactTerms: arg_exactTerms, excludeTerms: arg_excludeTerms, fi
leType: arg_fileType, filter: arg_filter, gl: arg_gl, googlehost: arg_googlehost
, highRange: arg_highRange, hl: arg_hl, hq: arg_hq, imgColorType: arg_imgColorTy
pe, imgDominantColor: arg_imgDominantColor, imgSize: arg_imgSize, imgType: arg_i
mgType, linkSite: arg_linkSite, lowRange: arg_lowRange, lr: arg_lr, num: arg_num
, orTerms: arg_orTerms, relatedSite: arg_relatedSite, rights: arg_rights, safe:
arg_safe, searchType: arg_searchType, siteSearch: arg_siteSearch, siteSearchFilt
er: arg_siteSearchFilter, sort: arg_sort, start: arg_start).then(unittest.expect
Async1(((api.Search response) { |
| 831 checkSearch(response); | 831 checkSearch(response); |
| 832 }))); | 832 }))); |
| 833 }); | 833 }); |
| 834 | 834 |
| 835 }); | 835 }); |
| 836 | 836 |
| 837 | 837 |
| 838 } | 838 } |
| 839 | 839 |
| OLD | NEW |