From 3139ec3018bd07018e1958c9bc0f4c21f0027ab2 Mon Sep 17 00:00:00 2001 From: Yongqin Liu Date: Wed, 14 Mar 2018 18:01:58 +0800 Subject: android monkey.sh: output the logcat for debug if the monkey failed to run all the events specified. Change-Id: I0d1c3893fd3bef6734554b8dac02b24b89566636 Signed-off-by: Yongqin Liu --- automated/android/monkey/monkey.sh | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'automated') diff --git a/automated/android/monkey/monkey.sh b/automated/android/monkey/monkey.sh index b865f8f..c7707d2 100755 --- a/automated/android/monkey/monkey.sh +++ b/automated/android/monkey/monkey.sh @@ -86,3 +86,8 @@ if grep -q "Network stats: elapsed time=" "${LOGFILE}"; then else report_fail "monkey-network-stats" fi + +if ! grep "Events injected: ${EVENT_COUNT}" "${LOGFILE}"; then + ## output the logcat information for debug when failed to run inject all the events + adb logcat -d -b all +fi -- cgit v1.2.3