@@ -52,7 +52,7 @@ void main() {
5252 Map <String , String >? dimensions,
5353 String ? prefix,
5454 bool verbose = false ,
55- io.ProcessResult Function (List < String > command ) onRun = _runUnhandled,
55+ io.ProcessResult Function (FakeCommandLogEntry entry ) onRun = _runUnhandled,
5656 }) {
5757 return SkiaGoldClient .forTesting (
5858 fixture.workDirectory,
@@ -97,8 +97,8 @@ void main() {
9797 final SkiaGoldClient client = createClient (
9898 fixture,
9999 environment: {...presubmitEnv, 'GIT_BRANCH' : 'merge-queue-foo' },
100- onRun: (List < String > command ) {
101- expect (command, < String > [
100+ onRun: (FakeCommandLogEntry entry ) {
101+ expect (entry. command, < String > [
102102 'python tools/goldctl.py' ,
103103 'auth' ,
104104 '--work-dir' ,
@@ -132,8 +132,8 @@ void main() {
132132 final SkiaGoldClient client = createClient (
133133 fixture,
134134 environment: {...presubmitEnv, 'GIT_BRANCH' : 'merge-queue-foo' },
135- onRun: (List < String > command ) {
136- expect (command, < String > [
135+ onRun: (FakeCommandLogEntry entry ) {
136+ expect (entry. command, < String > [
137137 'python tools/goldctl.py' ,
138138 'auth' ,
139139 '--work-dir' ,
@@ -165,8 +165,8 @@ void main() {
165165 final SkiaGoldClient client = createClient (
166166 fixture,
167167 environment: presubmitEnv,
168- onRun: (List < String > command ) {
169- expect (command, < String > [
168+ onRun: (FakeCommandLogEntry entry ) {
169+ expect (entry. command, < String > [
170170 'python tools/goldctl.py' ,
171171 'auth' ,
172172 '--work-dir' ,
@@ -190,9 +190,9 @@ void main() {
190190 final SkiaGoldClient client = createClient (
191191 fixture,
192192 environment: presubmitEnv,
193- onRun: (List < String > command ) {
193+ onRun: (FakeCommandLogEntry entry ) {
194194 callsToGoldctl++ ;
195- expect (command, < String > [
195+ expect (entry. command, < String > [
196196 'python tools/goldctl.py' ,
197197 'auth' ,
198198 '--work-dir' ,
@@ -219,8 +219,8 @@ void main() {
219219 fixture,
220220 environment: presubmitEnv,
221221 verbose: true ,
222- onRun: (List < String > command ) {
223- expect (command, < String > [
222+ onRun: (FakeCommandLogEntry entry ) {
223+ expect (entry. command, < String > [
224224 'python tools/goldctl.py' ,
225225 'auth' ,
226226 '--verbose' ,
@@ -246,7 +246,7 @@ void main() {
246246 final SkiaGoldClient client = createClient (
247247 fixture,
248248 environment: presubmitEnv,
249- onRun: (List < String > command ) {
249+ onRun: (FakeCommandLogEntry entry ) {
250250 return io.ProcessResult (1 , 0 , 'stdout-text' , 'stderr-text' );
251251 },
252252 );
@@ -270,14 +270,14 @@ void main() {
270270 final SkiaGoldClient client = createClient (
271271 fixture,
272272 environment: presubmitEnv,
273- onRun: (List < String > command ) {
274- if (command case ['git' , ...]) {
273+ onRun: (FakeCommandLogEntry entry ) {
274+ if (entry. command case ['git' , ...]) {
275275 return io.ProcessResult (0 , 0 , mockCommitHash, '' );
276276 }
277- if (command case ['python tools/goldctl.py' , 'imgtest' , 'init' , ...]) {
277+ if (entry. command case ['python tools/goldctl.py' , 'imgtest' , 'init' , ...]) {
278278 return io.ProcessResult (0 , 0 , '' , '' );
279279 }
280- expect (command, < String > [
280+ expect (entry. command, < String > [
281281 'python tools/goldctl.py' ,
282282 'imgtest' ,
283283 'add' ,
@@ -315,14 +315,14 @@ void main() {
315315 fixture,
316316 environment: presubmitEnv,
317317 prefix: 'engine.' ,
318- onRun: (List < String > command ) {
319- if (command case ['git' , ...]) {
318+ onRun: (FakeCommandLogEntry entry ) {
319+ if (entry. command case ['git' , ...]) {
320320 return io.ProcessResult (0 , 0 , mockCommitHash, '' );
321321 }
322- if (command case ['python tools/goldctl.py' , 'imgtest' , 'init' , ...]) {
322+ if (entry. command case ['python tools/goldctl.py' , 'imgtest' , 'init' , ...]) {
323323 return io.ProcessResult (0 , 0 , '' , '' );
324324 }
325- expect (command, < String > [
325+ expect (entry. command, < String > [
326326 'python tools/goldctl.py' ,
327327 'imgtest' ,
328328 'add' ,
@@ -363,14 +363,14 @@ void main() {
363363 final SkiaGoldClient client = createClient (
364364 fixture,
365365 environment: presubmitEnv,
366- onRun: (List < String > command ) {
367- if (command case ['git' , ...]) {
366+ onRun: (FakeCommandLogEntry entry ) {
367+ if (entry. command case ['git' , ...]) {
368368 return io.ProcessResult (0 , 0 , mockCommitHash, '' );
369369 }
370- if (command case ['python tools/goldctl.py' , 'imgtest' , 'init' , ...]) {
370+ if (entry. command case ['python tools/goldctl.py' , 'imgtest' , 'init' , ...]) {
371371 return io.ProcessResult (0 , 0 , '' , '' );
372372 }
373- expect (command, < String > [
373+ expect (entry. command, < String > [
374374 'python tools/goldctl.py' ,
375375 'imgtest' ,
376376 'add' ,
@@ -409,14 +409,14 @@ void main() {
409409 fixture,
410410 environment: presubmitEnv,
411411 verbose: true ,
412- onRun: (List < String > command ) {
413- if (command case ['git' , ...]) {
412+ onRun: (FakeCommandLogEntry entry ) {
413+ if (entry. command case ['git' , ...]) {
414414 return io.ProcessResult (0 , 0 , mockCommitHash, '' );
415415 }
416- if (command case ['python tools/goldctl.py' , 'imgtest' , 'init' , ...]) {
416+ if (entry. command case ['python tools/goldctl.py' , 'imgtest' , 'init' , ...]) {
417417 return io.ProcessResult (0 , 0 , '' , '' );
418418 }
419- expect (command, < String > [
419+ expect (entry. command, < String > [
420420 'python tools/goldctl.py' ,
421421 'imgtest' ,
422422 'add' ,
@@ -458,14 +458,14 @@ void main() {
458458 final SkiaGoldClient client = createClient (
459459 fixture,
460460 environment: presubmitEnv,
461- onRun: (List < String > command ) {
462- if (command case ['git' , ...]) {
461+ onRun: (FakeCommandLogEntry entry ) {
462+ if (entry. command case ['git' , ...]) {
463463 return io.ProcessResult (0 , 0 , mockCommitHash, '' );
464464 }
465- if (command case ['python tools/goldctl.py' , 'imgtest' , 'init' , ...]) {
465+ if (entry. command case ['python tools/goldctl.py' , 'imgtest' , 'init' , ...]) {
466466 return io.ProcessResult (0 , 0 , '' , '' );
467467 }
468- expect (command, < String > [
468+ expect (entry. command, < String > [
469469 'python tools/goldctl.py' ,
470470 'imgtest' ,
471471 'add' ,
@@ -507,11 +507,11 @@ void main() {
507507 final SkiaGoldClient client = createClient (
508508 fixture,
509509 environment: presubmitEnv,
510- onRun: (List < String > command ) {
511- if (command case ['git' , ...]) {
510+ onRun: (FakeCommandLogEntry entry ) {
511+ if (entry. command case ['git' , ...]) {
512512 return io.ProcessResult (0 , 0 , mockCommitHash, '' );
513513 }
514- if (command case ['python tools/goldctl.py' , 'imgtest' , 'init' , ...]) {
514+ if (entry. command case ['python tools/goldctl.py' , 'imgtest' , 'init' , ...]) {
515515 return io.ProcessResult (0 , 0 , '' , '' );
516516 }
517517 return io.ProcessResult (1 , 0 , 'stdout-text' , 'stderr-text' );
@@ -541,14 +541,14 @@ void main() {
541541 final SkiaGoldClient client = createClient (
542542 fixture,
543543 environment: postsubmitEnv,
544- onRun: (List < String > command ) {
545- if (command case ['git' , ...]) {
544+ onRun: (FakeCommandLogEntry entry ) {
545+ if (entry. command case ['git' , ...]) {
546546 return io.ProcessResult (0 , 0 , mockCommitHash, '' );
547547 }
548- if (command case ['python tools/goldctl.py' , 'imgtest' , 'init' , ...]) {
548+ if (entry. command case ['python tools/goldctl.py' , 'imgtest' , 'init' , ...]) {
549549 return io.ProcessResult (0 , 0 , '' , '' );
550550 }
551- expect (command, < String > [
551+ expect (entry. command, < String > [
552552 'python tools/goldctl.py' ,
553553 'imgtest' ,
554554 'add' ,
@@ -587,14 +587,14 @@ void main() {
587587 fixture,
588588 environment: postsubmitEnv,
589589 verbose: true ,
590- onRun: (List < String > command ) {
591- if (command case ['git' , ...]) {
590+ onRun: (FakeCommandLogEntry entry ) {
591+ if (entry. command case ['git' , ...]) {
592592 return io.ProcessResult (0 , 0 , mockCommitHash, '' );
593593 }
594- if (command case ['python tools/goldctl.py' , 'imgtest' , 'init' , ...]) {
594+ if (entry. command case ['python tools/goldctl.py' , 'imgtest' , 'init' , ...]) {
595595 return io.ProcessResult (0 , 0 , '' , '' );
596596 }
597- expect (command, < String > [
597+ expect (entry. command, < String > [
598598 'python tools/goldctl.py' ,
599599 'imgtest' ,
600600 'add' ,
@@ -636,11 +636,11 @@ void main() {
636636 final SkiaGoldClient client = createClient (
637637 fixture,
638638 environment: postsubmitEnv,
639- onRun: (List < String > command ) {
640- if (command case ['git' , ...]) {
639+ onRun: (FakeCommandLogEntry entry ) {
640+ if (entry. command case ['git' , ...]) {
641641 return io.ProcessResult (0 , 0 , mockCommitHash, '' );
642642 }
643- if (command case ['python tools/goldctl.py' , 'imgtest' , 'init' , ...]) {
643+ if (entry. command case ['python tools/goldctl.py' , 'imgtest' , 'init' , ...]) {
644644 return io.ProcessResult (0 , 0 , '' , '' );
645645 }
646646 return io.ProcessResult (1 , 0 , 'stdout-text' , 'stderr-text' );
@@ -670,8 +670,8 @@ void main() {
670670 final SkiaGoldClient client = createClient (
671671 fixture,
672672 environment: presubmitEnv,
673- onRun: (List < String > command ) {
674- expect (command, < String > [
673+ onRun: (FakeCommandLogEntry entry ) {
674+ expect (entry. command, < String > [
675675 'python tools/goldctl.py' ,
676676 'imgtest' ,
677677 'get' ,
@@ -728,8 +728,8 @@ final class _TestFixture {
728728 }
729729}
730730
731- io.ProcessResult _runUnhandled (List < String > command ) {
732- throw UnimplementedError ('Unhandled run: ${command .join (' ' )}' );
731+ io.ProcessResult _runUnhandled (FakeCommandLogEntry entry ) {
732+ throw UnimplementedError ('Unhandled run: ${entry . command .join (' ' )}' );
733733}
734734
735735/// An in-memory fake of [io.HttpClient] that allows [getUrl] to be mocked.
0 commit comments