OLD | NEW |
(Empty) | |
| 1 # Copyright 2014 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 |
| 5 |
| 6 # Recipe for the Skia PerCommit Housekeeper. |
| 7 |
| 8 |
| 9 DEPS = [ |
| 10 'recipe_engine/path', |
| 11 'recipe_engine/properties', |
| 12 'recipe_engine/python', |
| 13 'skia', |
| 14 'recipe_engine/step', |
| 15 ] |
| 16 |
| 17 |
| 18 TEST_BUILDERS = { |
| 19 'client.skia.fyi': { |
| 20 'skiabot-linux-housekeeper-000': [ |
| 21 'Housekeeper-PerCommit', |
| 22 'Housekeeper-PerCommit-Trybot', |
| 23 ], |
| 24 }, |
| 25 } |
| 26 |
| 27 |
| 28 def RunSteps(api): |
| 29 # Checkout, compile, etc. |
| 30 api.skia.setup() |
| 31 |
| 32 cwd = api.path['checkout'] |
| 33 |
| 34 api.skia.run( |
| 35 api.step, |
| 36 'android platform self-tests', |
| 37 cmd=['python', |
| 38 cwd.join('platform_tools', 'android', 'tests', 'run_all.py')], |
| 39 cwd=cwd, |
| 40 abort_on_failure=False) |
| 41 |
| 42 # TODO(borenet): Detect static initializers? |
| 43 |
| 44 gsutil_path = api.path['depot_tools'].join('third_party', 'gsutil', |
| 45 'gsutil') |
| 46 if not api.skia.is_trybot: |
| 47 api.skia.run( |
| 48 api.step, |
| 49 'generate and upload doxygen', |
| 50 cmd=['python', api.skia.resource('generate_and_upload_doxygen.py'), |
| 51 gsutil_path], |
| 52 cwd=cwd, |
| 53 abort_on_failure=False) |
| 54 |
| 55 cmd = ['python', api.skia.resource('run_binary_size_analysis.py'), |
| 56 '--library', api.skia.skia_out.join('Release', 'lib', 'libskia.so'), |
| 57 '--githash', api.properties['revision'], |
| 58 '--gsutil_path', gsutil_path] |
| 59 if api.skia.is_trybot: |
| 60 cmd.extend(['--issue_number', str(api.skia.m.properties['issue'])]) |
| 61 api.skia.run( |
| 62 api.step, |
| 63 'generate and upload binary size data', |
| 64 cmd=cmd, |
| 65 cwd=cwd, |
| 66 abort_on_failure=False) |
| 67 |
| 68 def GenTests(api): |
| 69 for mastername, slaves in TEST_BUILDERS.iteritems(): |
| 70 for slavename, builders_by_slave in slaves.iteritems(): |
| 71 for buildername in builders_by_slave: |
| 72 test = ( |
| 73 api.test(buildername) + |
| 74 api.properties(buildername=buildername, |
| 75 mastername=mastername, |
| 76 slavename=slavename, |
| 77 buildnumber=5, |
| 78 revision='abc123', |
| 79 path_config='kitchen', |
| 80 swarm_out_dir='[SWARM_OUT_DIR]') + |
| 81 api.path.exists(api.path['slave_build']) |
| 82 ) |
| 83 if 'Trybot' in buildername: |
| 84 test.properties['issue'] = '500' |
| 85 yield test |
OLD | NEW |