| OLD | NEW |
| 1 #!/usr/bin/env bash | 1 #!/usr/bin/env bash |
| 2 # Copyright (c) 2016 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2016 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 # Get the full directory path of this script regardless of where it's run from | 6 # Get the full directory path of this script regardless of where it's run from |
| 7 # Based on: http://stackoverflow.com/questions/59895/can-a-bash-script-tell-whic
h-directory-it-is-stored-in | 7 # Based on: http://stackoverflow.com/questions/59895/can-a-bash-script-tell-whic
h-directory-it-is-stored-in |
| 8 SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}" )" && pwd)" | 8 SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}" )" && pwd)" |
| 9 | 9 |
| 10 CHROMIUM_ROOT_PATH=${SCRIPT_PATH}"/../../../../.." | 10 CHROMIUM_ROOT_PATH=${SCRIPT_PATH}"/../../../../.." |
| 11 OUT_PATH=${CHROMIUM_ROOT_PATH}"/out/Release" | 11 OUT_PATH=${CHROMIUM_ROOT_PATH}"/out/Release" |
| 12 RUN_LAYOUT_TEST_PATH=${CHROMIUM_ROOT_PATH}"/blink/tools/run_layout_tests.py" | 12 RUN_LAYOUT_TEST_PATH=${CHROMIUM_ROOT_PATH}"/blink/tools/run_layout_tests.py" |
| 13 ALL_TESTS=" inspector** http/tests/inspector**" | 13 ALL_TESTS=" inspector** http/tests/inspector**" |
| 14 DEBUG_FLAG=" --additional-driver-flag=--debug-devtools --time-out-ms=6000000 --a
dditional-driver-flag=--remote-debugging-port=9222" | 14 DEBUG_FLAG=" --additional-driver-flag=--debug-devtools --time-out-ms=6000000 --a
dditional-driver-flag=--remote-debugging-port=9222" |
| 15 | 15 |
| 16 COMMAND=${RUN_LAYOUT_TEST_PATH} | 16 COMMAND=${RUN_LAYOUT_TEST_PATH} |
| 17 | 17 |
| 18 echo "====================================================" |
| 19 echo "This shell script is DEPRECATED and will be removed" |
| 20 echo "Please use 'npm test' instead" |
| 21 echo "See README.md on how to use" |
| 22 echo "====================================================" |
| 23 echo |
| 24 |
| 18 ninja -C ${OUT_PATH} devtools_frontend_resources | 25 ninja -C ${OUT_PATH} devtools_frontend_resources |
| 19 if [ "$1" == "-d" ] | 26 if [ "$1" == "-d" ] |
| 20 then | 27 then |
| 21 shift | 28 shift |
| 22 COMMAND=${COMMAND}${DEBUG_FLAG} | 29 COMMAND=${COMMAND}${DEBUG_FLAG} |
| 23 echo "============================" | 30 echo "============================" |
| 24 echo "Go to: http://localhost:9222" | 31 echo "Go to: http://localhost:9222" |
| 25 echo "============================" | 32 echo "============================" |
| 26 fi | 33 fi |
| 27 | 34 |
| 28 if [ $# -eq 0 ] | 35 if [ $# -eq 0 ] |
| 29 then | 36 then |
| 30 COMMAND=${COMMAND}${ALL_TESTS} | 37 COMMAND=${COMMAND}${ALL_TESTS} |
| 31 else | 38 else |
| 32 COMMAND=${COMMAND}" $@" | 39 COMMAND=${COMMAND}" $@" |
| 33 fi | 40 fi |
| 34 | 41 |
| 35 ${COMMAND} | 42 ${COMMAND} |
| OLD | NEW |