mirror of
https://github.com/flatcar/scripts.git
synced 2025-11-29 14:31:46 +01:00
Fixed run_remote_test.sh to work properly with the new location of chrome tests
BUG=none TEST=none Review URL: http://codereview.chromium.org/3341028 Change-Id: I81a8d57b16e7789b0fd6673d9e3b208ce369a575
This commit is contained in:
parent
cebafd2ec3
commit
90a850ac11
@ -163,9 +163,13 @@ function main() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
local control_files_to_run=""
|
local control_files_to_run=""
|
||||||
|
local chrome_autotests="${CHROME_ROOT}/src/chrome/test/chromeos/autotest/files"
|
||||||
# Now search for tests which unambiguously include the given identifier
|
# Now search for tests which unambiguously include the given identifier
|
||||||
local search_path=$(echo {client,server}/{tests,site_tests})
|
local search_path=$(echo {client,server}/{tests,site_tests})
|
||||||
|
# Include chrome autotest in the search path
|
||||||
|
if [ -n "${CHROME_ROOT}" ]; then
|
||||||
|
search_path="${search_path} ${chrome_autotests}/client/site_tests"
|
||||||
|
fi
|
||||||
pushd ${autotest_dir} > /dev/null
|
pushd ${autotest_dir} > /dev/null
|
||||||
for test_request in $FLAGS_ARGV; do
|
for test_request in $FLAGS_ARGV; do
|
||||||
test_request=$(remove_quotes "${test_request}")
|
test_request=$(remove_quotes "${test_request}")
|
||||||
@ -210,6 +214,10 @@ function main() {
|
|||||||
# Assume a line starts with TEST_TYPE =
|
# Assume a line starts with TEST_TYPE =
|
||||||
control_file=$(remove_quotes "${control_file}")
|
control_file=$(remove_quotes "${control_file}")
|
||||||
local type=$(read_test_type "${autotest_dir}/${control_file}")
|
local type=$(read_test_type "${autotest_dir}/${control_file}")
|
||||||
|
# Check if the control file is an absolute path (i.e. chrome autotests case)
|
||||||
|
if [[ ${control_file:0:1} == "/" ]]; then
|
||||||
|
type=$(read_test_type "${control_file}")
|
||||||
|
fi
|
||||||
local option
|
local option
|
||||||
if [[ "${type}" == "client" ]]; then
|
if [[ "${type}" == "client" ]]; then
|
||||||
option="-c"
|
option="-c"
|
||||||
@ -245,6 +253,13 @@ function main() {
|
|||||||
autotest="./autotest${WORKON_SUFFIX}"
|
autotest="./autotest${WORKON_SUFFIX}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Remove chrome autotest location prefix from control_file if needed
|
||||||
|
if [[ ${control_file:0:${#chrome_autotests}} == \
|
||||||
|
"${chrome_autotests}" ]]; then
|
||||||
|
control_file="${control_file:${#chrome_autotests}+1}"
|
||||||
|
echo_color "yellow" ">>> Running chrome autotest " ${control_file}
|
||||||
|
fi
|
||||||
|
|
||||||
${enter_chroot} ${autotest} --board "${FLAGS_board}" -m "${FLAGS_remote}" \
|
${enter_chroot} ${autotest} --board "${FLAGS_board}" -m "${FLAGS_remote}" \
|
||||||
--ssh-port ${FLAGS_ssh_port} \
|
--ssh-port ${FLAGS_ssh_port} \
|
||||||
"${option}" "${control_file}" -r "${results_dir}" ${verbose} \
|
"${option}" "${control_file}" -r "${results_dir}" ${verbose} \
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user