Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 #!/bin/bash | 1 #!/bin/bash |
| 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
| 4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
| 5 # | 5 # |
| 6 # Bash functions used by buildbot annotator scripts for the android | 6 # Bash functions used by buildbot annotator scripts for the android |
| 7 # build of chromium. Executing this script should not perform actions | 7 # build of chromium. Executing this script should not perform actions |
| 8 # other than setting variables and defining of functions. | 8 # other than setting variables and defining of functions. |
| 9 | 9 |
| 10 # Number of jobs on the compile line; e.g. make -j"${JOBS}" | 10 # Number of jobs on the compile line; e.g. make -j"${JOBS}" |
| (...skipping 199 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 210 | 210 |
| 211 # Run experimental unittest bundles. | 211 # Run experimental unittest bundles. |
| 212 function bb_run_experimental_unit_tests { | 212 function bb_run_experimental_unit_tests { |
| 213 # This build step was added because bash does not allow empty functions. | 213 # This build step was added because bash does not allow empty functions. |
| 214 # run_tests.py echoes a build step, comment/remove this build step when you | 214 # run_tests.py echoes a build step, comment/remove this build step when you |
| 215 # add tests to the experimental step. | 215 # add tests to the experimental step. |
| 216 echo '@@@BUILD_STEP experimental_unit_tests@@@' | 216 echo '@@@BUILD_STEP experimental_unit_tests@@@' |
| 217 | 217 |
| 218 } | 218 } |
| 219 | 219 |
| 220 # Run findbugs. | |
| 221 function bb_run_findbugs_diff { | |
| 222 build/android/findbugs_diff.py | |
|
Yaron
2012/11/02 00:09:47
Both of these should echo a BUILD_STEP
michaelbai
2012/11/02 00:31:19
Done.
| |
| 223 } | |
| 224 | |
| 225 # Run findbugs plugin tests. | |
| 226 function bb_run_findbugs_plugin_tests { | |
| 227 tools/android/findbugs_plugin/test/run_findbugs_plugin_tests.py | |
| 228 } | |
| 229 | |
| 220 # Run a buildbot step and handle failure. | 230 # Run a buildbot step and handle failure. |
| 221 function bb_run_step { | 231 function bb_run_step { |
| 222 ( | 232 ( |
| 223 set +e | 233 set +e |
| 224 "$@" | 234 "$@" |
| 225 if [[ $? != 0 ]]; then | 235 if [[ $? != 0 ]]; then |
| 226 echo "@@@STEP_FAILURE@@@" | 236 echo "@@@STEP_FAILURE@@@" |
| 227 fi | 237 fi |
| 228 ) | 238 ) |
| 229 } | 239 } |
| (...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 324 ) | 334 ) |
| 325 } | 335 } |
| 326 | 336 |
| 327 # Retrieve a packed json property using python | 337 # Retrieve a packed json property using python |
| 328 function bb_get_json_prop { | 338 function bb_get_json_prop { |
| 329 local JSON="$1" | 339 local JSON="$1" |
| 330 local PROP="$2" | 340 local PROP="$2" |
| 331 | 341 |
| 332 python -c "import json; print json.loads('$JSON').get('$PROP', '')" | 342 python -c "import json; print json.loads('$JSON').get('$PROP', '')" |
| 333 } | 343 } |
| OLD | NEW |