| OLD | NEW |
| 1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. |
| 2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 | 5 |
| 6 DEPS = [ | 6 DEPS = [ |
| 7 'gclient', | 7 'gclient', |
| 8 'git', | 8 'git', |
| 9 'path', | 9 'path', |
| 10 'platform', | 10 'platform', |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 45 'submodule update', api.path.depot_tools('gclient.py'), | 45 'submodule update', api.path.depot_tools('gclient.py'), |
| 46 ['recurse', 'git', 'submodule', 'update', '--init', '--recursive']) | 46 ['recurse', 'git', 'submodule', 'update', '--init', '--recursive']) |
| 47 | 47 |
| 48 return ( | 48 return ( |
| 49 api.gclient.checkout(cfg), | 49 api.gclient.checkout(cfg), |
| 50 submodule_command | 50 submodule_command |
| 51 ) | 51 ) |
| 52 | 52 |
| 53 | 53 |
| 54 def GenSteps(api): | 54 def GenSteps(api): |
| 55 | |
| 56 yield _CheckoutSteps(api) | 55 yield _CheckoutSteps(api) |
| 57 this_repo = api.properties['buildername'].split()[0] | 56 this_repo = api.properties['buildername'].split()[0] |
| 58 api.path.choose_checkout(api.path.slave_build(this_repo)) | 57 api.path.set_dynamic_path('checkout', api.path.slave_build(this_repo)) |
| 59 | 58 |
| 60 tmp_path = '' | 59 tmp_path = '' |
| 61 tmp_args = [] | 60 tmp_args = [] |
| 62 if not api.platform.is_win: | 61 if not api.platform.is_win: |
| 63 tmp_path = api.path.slave_build('.tmp') | 62 tmp_path = api.path.slave_build('.tmp') |
| 64 yield api.path.makedirs('tmp', tmp_path) | 63 yield api.path.makedirs('tmp', tmp_path) |
| 65 tmp_args = ['--tmp', tmp_path] | 64 tmp_args = ['--tmp', tmp_path] |
| 66 | 65 |
| 67 cmd_suffix = '' | 66 cmd_suffix = '' |
| 68 node_env = {} | 67 node_env = {} |
| (...skipping 11 matching lines...) Expand all Loading... |
| 80 'IE_BIN': | 79 'IE_BIN': |
| 81 api.path.join('C:', api.path.sep, 'Program Files', 'Internet Explorer', | 80 api.path.join('C:', api.path.sep, 'Program Files', 'Internet Explorer', |
| 82 'iexplore.exe'), | 81 'iexplore.exe'), |
| 83 } | 82 } |
| 84 | 83 |
| 85 test_prefix = [] | 84 test_prefix = [] |
| 86 if api.platform.is_linux: | 85 if api.platform.is_linux: |
| 87 test_prefix = ['xvfb-run'] | 86 test_prefix = ['xvfb-run'] |
| 88 | 87 |
| 89 yield api.step('update-install', ['npm' + cmd_suffix, 'install'] + tmp_args, | 88 yield api.step('update-install', ['npm' + cmd_suffix, 'install'] + tmp_args, |
| 90 cwd=api.path.checkout(), env=node_env) | 89 cwd=api.path.checkout, env=node_env) |
| 91 | 90 |
| 92 yield api.step('test', test_prefix + ['grunt' + cmd_suffix, | 91 yield api.step('test', test_prefix + ['grunt' + cmd_suffix, |
| 93 'test-buildbot'], cwd=api.path.checkout(), | 92 'test-buildbot'], cwd=api.path.checkout, |
| 94 env=node_env, allow_subannotations=True) | 93 env=node_env, allow_subannotations=True) |
| 95 | 94 |
| 96 | 95 |
| 97 def GenTests(api): | 96 def GenTests(api): |
| 98 # Test paths and commands on each platform. | 97 # Test paths and commands on each platform. |
| 99 for plat in ('mac', 'linux', 'win'): | 98 for plat in ('mac', 'linux', 'win'): |
| 100 yield ( | 99 yield ( |
| 101 api.test('polymer-%s' % plat) + | 100 api.test('polymer-%s' % plat) + |
| 102 api.properties.scheduled( | 101 api.properties.scheduled( |
| 103 repository='https://github.com/Polymer/polymer', | 102 repository='https://github.com/Polymer/polymer', |
| 104 buildername='polymer %s' % plat, | 103 buildername='polymer %s' % plat, |
| 105 ) + | 104 ) + |
| 106 api.platform.name(plat) | 105 api.platform.name(plat) |
| 107 ) | 106 ) |
| 108 | 107 |
| 109 # Make sure the steps are right for deps-triggered jobs. | 108 # Make sure the steps are right for deps-triggered jobs. |
| 110 yield ( | 109 yield ( |
| 111 api.test('polymer-from-platform') + | 110 api.test('polymer-from-platform') + |
| 112 api.properties.scheduled( | 111 api.properties.scheduled( |
| 113 repository='https://github.com/Polymer/platform', | 112 repository='https://github.com/Polymer/platform', |
| 114 buildername='polymer linux', | 113 buildername='polymer linux', |
| 115 scheduler='polymer-platform' | 114 scheduler='polymer-platform' |
| 116 ) | 115 ) |
| 117 ) | 116 ) |
| OLD | NEW |