• 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.join('work')
21  out_dir = checkout_root.join(
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.join('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-GCC-x86-Debug-Docker',
31  'Build-Debian10-GCC-x86_64-Debug-Docker',
32  'Build-Debian10-GCC-x86_64-Release-NoGPU_Docker',
33  'Build-Debian10-GCC-x86_64-Release-Shared_Docker',
34  'Build-Debian10-Clang-arm-Release-Android_API26',
35  'Build-Debian10-Clang-arm-Release-Android_ASAN',
36  'Build-Debian10-Clang-arm-OptimizeForSize-Android_NoPatch',
37  'Build-Debian10-Clang-arm-Release-Chromebook_GLES',
38  'Build-Debian10-Clang-arm64-Debug-Android_FrameworkWorkarounds',
39  'Build-Debian10-Clang-arm64-Debug-Android_Graphite_Vulkan',
40  'Build-Debian10-Clang-arm64-Debug-Android_HWASAN',
41  'Build-Debian10-Clang-arm64-Release-Android_Graphite_Dawn',
42  'Build-Debian10-Clang-arm64-Release-Android_Wuffs',
43  'Build-Debian10-Clang-x86_64-Debug-ASAN_Graphite_Vulkan',
44  'Build-Debian10-Clang-x86_64-Debug-AVIF',
45  'Build-Debian10-Clang-x86_64-Debug-Chromebook_GLES',
46  'Build-Debian10-Clang-x86_64-Debug-Coverage',
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-Static',
64  'Build-Debian10-Clang-x86_64-Release-SwiftShader',
65  'Build-Debian10-Clang-x86_64-Release-Vulkan',
66  'Build-Debian10-EMCC-asmjs-Debug-PathKit',
67  'Build-Debian10-EMCC-asmjs-Release-PathKit',
68  'Build-Debian10-EMCC-wasm-Debug-CanvasKit',
69  'Build-Debian10-EMCC-wasm-Debug-PathKit',
70  'Build-Debian10-EMCC-wasm-Release-CanvasKit_CPU',
71  'Build-Debian10-EMCC-wasm-Release-PathKit',
72  'Build-Mac-Clang-arm64-Debug-Android_Vulkan',
73  'Build-Mac-Clang-arm64-Debug-iOS',
74  "Build-Mac-Clang-arm64-Debug-Graphite_Dawn",
75  "Build-Mac-Clang-arm64-Debug-Graphite_Dawn_NoGpu",
76  "Build-Mac-Clang-arm64-Debug-Graphite_Dawn_NoPrecompile",
77  "Build-Mac-Clang-arm64-Debug-Graphite_Metal",
78  "Build-Mac-Clang-arm64-Debug-Graphite_Metal_NoGpu",
79  "Build-Mac-Clang-arm64-Debug-Graphite_Metal_NoPrecompile",
80  "Build-Mac-Clang-arm64-Release-Graphite_Metal",
81  "Build-Mac-Clang-arm64-Release-Graphite_Dawn",
82  'Build-Mac-Xcode11.4.1-arm64-Debug-iOS',
83  'Build-Mac-Clang-x86_64-Debug-ASAN',
84  'Build-Mac-Clang-x86_64-Debug-Metal',
85  'Build-Win-Clang-arm64-Release-Android',
86  'Build-Win-Clang-x86-Debug-Exceptions',
87  'Build-Win-Clang-x86_64-Debug-ANGLE',
88  'Build-Win-Clang-x86_64-Release-Graphite_Vulkan',
89  'Build-Win-Clang-x86_64-Release-Direct3D',
90  'Build-Win-Clang-x86_64-Release-Shared',
91  "Build-Win-Clang-x86_64-Release-Dawn",
92  'Build-Win-Clang-x86_64-Release-Vulkan',
93]
94
95# Default properties used for TEST_BUILDERS.
96defaultProps = lambda buildername: dict(
97  buildername=buildername,
98  repository='https://skia.googlesource.com/skia.git',
99  revision='abc123',
100  path_config='kitchen',
101  patch_set=2,
102  swarm_out_dir='[SWARM_OUT_DIR]'
103)
104
105def GenTests(api):
106  for buildername in TEST_BUILDERS:
107    test = (
108      api.test(buildername) +
109      api.properties(**defaultProps(buildername))
110    )
111    if 'Win' in buildername:
112      test += api.platform('win', 64)
113    yield test
114
115  yield (
116      api.test('unknown-docker-image') +
117      api.properties(**defaultProps('Build-Unix-GCC-x86_64-Release-Docker')) +
118      api.expect_exception('Exception')
119  )
120