summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMaxim Siniavine <siniavine@google.com>2013-11-11 16:08:17 -0800
committerMaxim Siniavine <siniavine@google.com>2013-11-11 16:08:17 -0800
commiteba0081f35f5f58cc2bc696c1d58b97507c38143 (patch)
treed86cd0a1a058026ef70ab3a9b3777d9c7141bc04
parente56eec3dd5c1b5931ecc54d6aa954f1d8a3f53fa (diff)
downloadtesting-kitkat-mr1.1-release.tar.gz
When only jar files were provided as arguments to runtest command the script would display a help message rather than running the test. BUG: 11634975 Change-Id: I3ce9060ffbdcc9a7e39bbd04de491eb9f0cbfc9f
-rwxr-xr-xuiautomator/cmds/uiautomator/uiautomator5
1 files changed, 4 insertions, 1 deletions
diff --git a/uiautomator/cmds/uiautomator/uiautomator b/uiautomator/cmds/uiautomator/uiautomator
index 9aec2c4..fe2c735 100755
--- a/uiautomator/cmds/uiautomator/uiautomator
+++ b/uiautomator/cmds/uiautomator/uiautomator
@@ -69,11 +69,14 @@ jars=
if [ "${cmd}" == "runtest" ]; then
# first parse the jar paths
while [ true ]; do
- if [ -z "${1}" ]; then
+ if [ -z "${1}" ] && [ -z "${jars}" ]; then
echo "Error: more parameters expected for runtest; please see usage for details"
cmd="help"
break
fi
+ if [ -z "${1}" ]; then
+ break
+ fi
jar=${1}
if [ "${1:0:1}" = "-" ]; then
# we are done with jars, starting with parameters now