diff --git a/infra/bots/gen_tasks.go b/infra/bots/gen_tasks.go index 70c293873f..077c709a8a 100644 --- a/infra/bots/gen_tasks.go +++ b/infra/bots/gen_tasks.go @@ -62,7 +62,7 @@ var ( // internalHardwareLabelFn can be set in an init function to provide an // internal_hardware_label variable to the recipe. - internalHardwareLabelFn func(parts map[string]string) *string + internalHardwareLabelFn func(parts map[string]string) *int // Defines the structure of job names. jobNameSchema *JobNameSchema @@ -87,7 +87,7 @@ var ( ) // internalHardwareLabel returns the internal ID for the bot, if any. -func internalHardwareLabel(parts map[string]string) *string { +func internalHardwareLabel(parts map[string]string) *int { if internalHardwareLabelFn != nil { return internalHardwareLabelFn(parts) } @@ -728,7 +728,7 @@ func test(b *specs.TasksCfgBuilder, name string, parts map[string]string, compil } iid := internalHardwareLabel(parts) if iid != nil { - s.ExtraArgs = append(s.ExtraArgs, fmt.Sprintf("internal_hardware_label=%s", *iid)) + s.ExtraArgs = append(s.ExtraArgs, fmt.Sprintf("internal_hardware_label=%d", *iid)) } b.MustAddTask(name, s) @@ -822,7 +822,7 @@ func perf(b *specs.TasksCfgBuilder, name string, parts map[string]string, compil } iid := internalHardwareLabel(parts) if iid != nil { - s.ExtraArgs = append(s.ExtraArgs, fmt.Sprintf("internal_hardware_label=%s", *iid)) + s.ExtraArgs = append(s.ExtraArgs, fmt.Sprintf("internal_hardware_label=%d", *iid)) } b.MustAddTask(name, s) diff --git a/infra/bots/recipes/test.py b/infra/bots/recipes/test.py index bbd80f220b..1f1a6e8d1d 100644 --- a/infra/bots/recipes/test.py +++ b/infra/bots/recipes/test.py @@ -233,7 +233,7 @@ def dm_flags(api, bot): args.extend(['--pr', 'ccpr']) # Bogus test for internal bot. - if api.vars.internal_hardware_label == '0': + if api.vars.internal_hardware_label == 0: args.append('--internal0') args.append('--config') @@ -1096,7 +1096,7 @@ def GenTests(api): revision='abc123', path_config='kitchen', swarm_out_dir='[SWARM_OUT_DIR]', - internal_hardware_label='0') + + internal_hardware_label=0) + api.path.exists( api.path['start_dir'].join('skia'), api.path['start_dir'].join('skia', 'infra', 'bots', 'assets',