Commit 78851e09 authored by bulach@chromium.org's avatar bulach@chromium.org

Android: follow up on instrumentation tests.

Follow up from:
http://codereview.chromium.org/10826071/
Build and install content shell on all attached devices.

BUG=139365
TEST=Android FYI tester runs instrumentation tests.


Review URL: https://chromiumcodereview.appspot.com/10825100

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@149186 0039d316-1c4b-4281-b951-d872f2087c98
parent 1dd6ac9f
...@@ -29,6 +29,7 @@ ...@@ -29,6 +29,7 @@
'type': 'none', 'type': 'none',
'dependencies': [ 'dependencies': [
'../base/base.gyp:base_unittests', '../base/base.gyp:base_unittests',
'../content/content.gyp:content_shell_test_apk',
'../content/content.gyp:content_unittests', '../content/content.gyp:content_unittests',
'../chrome/chrome.gyp:unit_tests', '../chrome/chrome.gyp:unit_tests',
'../gpu/gpu.gyp:gpu_unittests', '../gpu/gpu.gyp:gpu_unittests',
......
...@@ -4,6 +4,23 @@ ...@@ -4,6 +4,23 @@
# Use of this source code is governed by a BSD-style license that can be # Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file. # found in the LICENSE file.
# install -r doesn't always work? Try uninstalling first. CONTENT_SHELL_APK=${CHROME_SRC}/out/Release/content_shell/ContentShell-debug.apk
adb uninstall org.chromium.content_shell
adb install -r ${CHROME_SRC}/out/Release/content_shell/ContentShell-debug.apk if [ ! -f "${CONTENT_SHELL_APK}" ]; then
echo "Error: Could not find ${CONTENT_SHELL_APK} to install."
exit 1
fi
DEVS=$(adb devices | grep device | grep -v devices | awk '{ print $1 }')
if [[ -z $DEVS ]]; then
echo "Error: No connected devices. Device needed to run content shell test."
exit 1
fi
for DEV in ${DEVS}; do
# Reinstall content shell. This will also kill existing content_shell procs.
echo "Installing ${CONTENT_SHELL_APK} in ${DEV}"
adb -s ${DEV} uninstall org.chromium.content_shell
adb -s ${DEV} install -r ${CONTENT_SHELL_APK}
done
...@@ -265,6 +265,7 @@ function bb_run_content_shell_test { ...@@ -265,6 +265,7 @@ function bb_run_content_shell_test {
function bb_run_content_shell_instrumentation_test { function bb_run_content_shell_instrumentation_test {
echo "@@@BUILD_STEP Run content shell instrumentation test on actual "\ echo "@@@BUILD_STEP Run content shell instrumentation test on actual "\
"hardware@@@" "hardware@@@"
build/android/adb_install_content_shell
build/android/run_instrumentation_tests.py -I \ build/android/run_instrumentation_tests.py -I \
--test-apk content_shell_test/ContentShellTest-debug -vvv --test-apk content_shell_test/ContentShellTest-debug -vvv
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment