Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit bbe5876

Browse files
authored
Conditionally run golden_tests_harvester for run_impeller_golden_tests. (#51325)
I think this restores the behavior prior to #50844 without making the client code faulty. I'll file a follow-up issue, I don't think `golden_tests_harvester` should accept running if `GOLDCTL` isn't set: flutter/flutter#144948. /cc @godofredoc
1 parent b178aa5 commit bbe5876

1 file changed

Lines changed: 10 additions & 0 deletions

File tree

testing/run_tests.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1052,6 +1052,16 @@ def run_impeller_golden_tests(build_dir: str):
10521052
print(diff_result.stdout.decode())
10531053
raise RuntimeError('impeller_golden_tests diff failure')
10541054

1055+
# On release builds and local builds, we typically do not have GOLDCTL set,
1056+
# which on other words means that this invoking the SkiaGoldClient would
1057+
# throw. Skip this step in those cases and log a notice.
1058+
if 'GOLDCTL' not in os.environ:
1059+
print_divider('<')
1060+
print(
1061+
'Skipping the SkiaGoldClient invocation as the GOLDCTL environment variable is not set.'
1062+
)
1063+
return
1064+
10551065
with DirectoryChange(harvester_path):
10561066
bin_path = Path('.').joinpath('bin').joinpath('golden_tests_harvester.dart')
10571067
run_cmd([dart_bin, 'run', str(bin_path), temp_dir])

0 commit comments

Comments
 (0)