• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright 2017 The Chromium Authors. All rights reserved.
2# Use of this source code is governed by a BSD-style license that can be
3# found in the LICENSE file.
4
5PYTHON_VERSION_COMPATIBILITY = 'PY3'
6
7DEPS = [
8  'build',
9  'recipe_engine/path',
10  'recipe_engine/platform',
11  'recipe_engine/properties',
12  'recipe_engine/raw_io',
13  'run',
14  'vars',
15]
16
17
18def RunSteps(api):
19  api.vars.setup()
20  checkout_root = api.vars.cache_dir.joinpath('work')
21  out_dir = checkout_root.joinpath(
22      'skia', 'out', api.vars.builder_name, api.vars.configuration)
23  api.build(checkout_root=checkout_root, out_dir=out_dir)
24  dst = api.vars.swarming_out_dir.joinpath('out', api.vars.configuration)
25  api.build.copy_build_products(out_dir=out_dir, dst=dst)
26  api.run.check_failure()
27
28
29TEST_BUILDERS = [
30  'Build-Debian10-Clang-arm-Release-Android_API26',
31  'Build-Debian10-Clang-arm-Release-Android_ASAN',
32  'Build-Debian10-Clang-arm-OptimizeForSize-Android_NoPatch',
33  'Build-Debian10-Clang-arm-Release-Chromebook_GLES',
34  'Build-Debian10-Clang-arm64-Debug-Android_FrameworkWorkarounds',
35  'Build-Debian10-Clang-arm64-Debug-Android_Graphite_Native_Vulkan',
36  'Build-Debian10-Clang-arm64-Debug-Android_HWASAN',
37  'Build-Debian10-Clang-arm64-Debug-Chromebook_GLES',
38  'Build-Debian10-Clang-arm64-Release-Android_Graphite_Dawn_GLES',
39  'Build-Debian10-Clang-arm64-Release-Android_Graphite_Dawn_Vulkan',
40  'Build-Debian10-Clang-arm64-Release-Android_Wuffs',
41  'Build-Debian10-Clang-x86_64-Debug-ASAN_Graphite_Native_Vulkan',
42  'Build-Debian10-Clang-x86_64-Debug-AVIF',
43  'Build-Debian10-Clang-x86_64-Debug-Chromebook_GLES',
44  'Build-Debian10-Clang-x86_64-Debug-Coverage',
45  'Build-Debian10-Clang-x86_64-Debug-Fontations',
46  'Build-Debian10-Clang-x86_64-Debug-FreeType',
47  'Build-Debian10-Clang-x86_64-Debug-MSAN',
48  'Build-Debian10-Clang-x86_64-Debug-SK_CPU_LIMIT_SSE41',
49  'Build-Debian10-Clang-x86_64-Debug-SafeStack',
50  'Build-Debian10-Clang-x86_64-Debug-SwiftShader_Graphite',
51  'Build-Debian10-Clang-x86_64-Debug-SwiftShader_MSAN',
52  'Build-Debian10-Clang-x86_64-Debug-TSAN',
53  'Build-Debian10-Clang-x86_64-Debug-Tidy',
54  'Build-Debian10-Clang-x86_64-Debug-Vulkan_TSAN',
55  'Build-Debian10-Clang-x86_64-Debug-Wuffs',
56  'Build-Debian10-Clang-x86_64-OptimizeForSize',
57  'Build-Debian10-Clang-x86_64-Release-ANGLE',
58  'Build-Debian10-Clang-x86_64-Release-ASAN',
59  'Build-Debian10-Clang-x86_64-Release-AVIF',
60  'Build-Debian10-Clang-x86_64-Release-CMake',
61  'Build-Debian10-Clang-x86_64-Release-Fast',
62  'Build-Debian10-Clang-x86_64-Release-NoDEPS',
63  'Build-Debian10-Clang-x86_64-Release-RustPNG',
64  'Build-Debian10-Clang-x86_64-Release-Static',
65  'Build-Debian10-Clang-x86_64-Release-SwiftShader',
66  'Build-Debian10-Clang-x86_64-Release-Vulkan',
67  'Build-Debian10-EMCC-asmjs-Debug-PathKit',
68  'Build-Debian10-EMCC-asmjs-Release-PathKit',
69  'Build-Debian10-EMCC-wasm-Debug-CanvasKit',
70  'Build-Debian10-EMCC-wasm-Debug-PathKit',
71  'Build-Debian10-EMCC-wasm-Release-CanvasKit_CPU',
72  'Build-Debian10-EMCC-wasm-Release-CanvasKit_WebGPU',
73  'Build-Debian10-EMCC-wasm-Release-PathKit',
74  'Build-Debian11-GCC-x86-Debug-Docker',
75  'Build-Debian11-GCC-x86_64-Debug-Docker',
76  'Build-Debian11-GCC-x86_64-Release-NoGPU_Docker',
77  'Build-Debian11-GCC-x86_64-Release-Shared_Docker',
78  'Build-Mac-Clang-arm64-Debug-Android_Vulkan',
79  'Build-Mac-Clang-arm64-Debug-iOS',
80  'Build-Mac-Clang-arm64-Debug-Graphite_Dawn_Metal',
81  'Build-Mac-Clang-arm64-Debug-Graphite_Dawn_Metal_NoGpu',
82  'Build-Mac-Clang-arm64-Debug-Graphite_Dawn_Metal_NoPrecompile',
83  'Build-Mac-Clang-arm64-Debug-Graphite_Native_Metal',
84  'Build-Mac-Clang-arm64-Debug-Graphite_Native_Metal_NoGpu',
85  'Build-Mac-Clang-arm64-Debug-Graphite_Native_Metal_NoPrecompile',
86  'Build-Mac-Clang-arm64-Release-Graphite_Native_Metal',
87  'Build-Mac-Clang-arm64-Release-Graphite_Native_Dawn_Metal',
88  'Build-Mac-Clang-x86_64-Release-Graphite_Native_Metal_Vello',
89  'Build-Mac-Clang-arm64-Debug-iOS_iOS12',
90  'Build-Mac-Clang-x86_64-Debug-ASAN',
91  'Build-Mac-Clang-x86_64-Debug-Metal',
92  'Build-Mac-Clang-arm64-Release-iOS18_Metal',
93  'Build-Win-Clang-arm64-Release-Android',
94  'Build-Win-Clang-x86-Debug-Exceptions',
95  'Build-Win-Clang-x86_64-Debug-ANGLE',
96  'Build-Win-Clang-x86_64-Release-Graphite_Native_Vulkan',
97  'Build-Win-Clang-x86_64-Release-Direct3D',
98  'Build-Win-Clang-x86_64-Release-Shared',
99  'Build-Win-Clang-x86_64-Release-Vulkan',
100  'Build-Win-MSVC-x86_64-Release-Graphite_Dawn_D3D11',
101  'Build-Win-MSVC-x86_64-Release-Graphite_Dawn_D3D12',
102  'Build-Debian10-Clang-x86_64-Release-SK_USE_PADDED_BLUR_UPSCALE',
103]
104
105# Default properties used for TEST_BUILDERS.
106defaultProps = lambda buildername: dict(
107  buildername=buildername,
108  repository='https://skia.googlesource.com/skia.git',
109  revision='abc123',
110  path_config='kitchen',
111  patch_set=2,
112  swarm_out_dir='[SWARM_OUT_DIR]'
113)
114
115def GenTests(api):
116  for buildername in TEST_BUILDERS:
117    test = (
118      api.test(buildername) +
119      api.properties(**defaultProps(buildername))
120    )
121    if 'Win' in buildername:
122      test += api.platform('win', 64)
123    yield test
124
125  yield (
126      api.test('unknown-docker-image') +
127      api.properties(**defaultProps('Build-Unix-GCC-x86_64-Release-Docker')) +
128      api.expect_exception('Exception')
129  )
130