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 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
55 yield _CheckoutSteps(api) | 55 yield _CheckoutSteps(api) |
56 | 56 |
57 tmp_path = '' | 57 tmp_path = '' |
58 tmp_args = [] | 58 tmp_args = [] |
59 if not api.platform.is_win: | 59 if not api.platform.is_win: |
60 tmp_path = api.path.slave_build('.tmp') | 60 tmp_path = api.path.slave_build('.tmp') |
61 yield api.step('mktmp', ['mkdir', '-p', tmp_path]) | 61 yield api.step('mktmp', ['mkdir', '-p', tmp_path]) |
62 tmp_args = ['--tmp', tmp_path] | 62 tmp_args = ['--tmp', tmp_path] |
63 | 63 |
64 cmd_suffix = '' | 64 cmd_suffix = '' |
65 npm_env = grunt_env = {} | 65 node_env = {} |
66 if api.platform.is_win: | 66 if api.platform.is_win: |
67 cmd_suffix = '.cmd' | 67 cmd_suffix = '.cmd' |
68 npm_env = {'PATH': r'C:\Program Files (x86)\nodejs;%(PATH)s'} | 68 node_env = {'PATH': r'C:\Program Files (x86)\nodejs;' |
69 grunt_env = {'PATH': r'C:\Users\chrome-bot\AppData\Roaming\npm;%(PATH)s'} | 69 r'C:\Users\chrome-bot\AppData\Roaming\npm;' |
| 70 r'%(PATH)s'} |
70 | 71 |
71 test_prefix = [] | 72 test_prefix = [] |
72 if api.platform.is_linux: | 73 if api.platform.is_linux: |
73 test_prefix = ['xvfb-run'] | 74 test_prefix = ['xvfb-run'] |
74 | 75 |
75 yield api.step('update-install', ['npm' + cmd_suffix, 'install'] + tmp_args, | 76 yield api.step('update-install', ['npm' + cmd_suffix, 'install'] + tmp_args, |
76 cwd=api.path.checkout(), env=npm_env) | 77 cwd=api.path.checkout(), env=node_env) |
77 | 78 |
78 yield api.step('test', test_prefix + ['grunt' + cmd_suffix, 'test-buildbot'], | 79 yield api.step('test', test_prefix + ['grunt' + cmd_suffix, 'test-buildbot'], |
79 cwd=api.path.checkout(), env=grunt_env, | 80 cwd=api.path.checkout(), env=node_env, |
80 allow_subannotations=True) | 81 allow_subannotations=True) |
81 | 82 |
82 | 83 |
83 def GenTests(api): | 84 def GenTests(api): |
84 for plat in ('mac', 'linux', 'win'): | 85 for plat in ('mac', 'linux', 'win'): |
85 yield 'polymer-%s' % plat, { | 86 yield 'polymer-%s' % plat, { |
86 'properties': api.properties_scheduled( | 87 'properties': api.properties_scheduled( |
87 repository='https://github.com/Polymer/polymer'), | 88 repository='https://github.com/Polymer/polymer'), |
88 'mock': { | 89 'mock': { |
89 'platform': { | 90 'platform': { |
90 'name': plat | 91 'name': plat |
91 } | 92 } |
92 }, | 93 }, |
93 } | 94 } |
OLD | NEW |