Loading tests/tapl/com/android/launcher3/tapl/LauncherInstrumentation.java +8 −7 Original line number Original line Diff line number Diff line Loading @@ -450,7 +450,7 @@ public final class LauncherInstrumentation { } } } } dumpDiagnostics(); dumpDiagnostics(message); log("Hierarchy dump for: " + message); log("Hierarchy dump for: " + message); dumpViewHierarchy(); dumpViewHierarchy(); Loading @@ -458,10 +458,11 @@ public final class LauncherInstrumentation { return message; return message; } } private void dumpDiagnostics() { private void dumpDiagnostics(String message) { Log.e("b/156287114", "Input:"); log("Diagnostics for failure: " + message); log("Input:"); logShellCommand("dumpsys input"); logShellCommand("dumpsys input"); Log.e("b/156287114", "TIS:"); log("TIS:"); logShellCommand("dumpsys activity service TouchInteractionService"); logShellCommand("dumpsys activity service TouchInteractionService"); } } Loading @@ -469,10 +470,10 @@ public final class LauncherInstrumentation { try { try { for (String line : mDevice.executeShellCommand(command).split("\\n")) { for (String line : mDevice.executeShellCommand(command).split("\\n")) { SystemClock.sleep(10); SystemClock.sleep(10); Log.d("b/156287114", line); log(line); } } } catch (IOException e) { } catch (IOException e) { Log.d("b/156287114", "Failed to execute " + command); log("Failed to execute " + command); } } } } Loading Loading @@ -1362,7 +1363,7 @@ public final class LauncherInstrumentation { if (mCheckEventsForSuccessfulGestures) { if (mCheckEventsForSuccessfulGestures) { final String message = eventChecker.verify(WAIT_TIME_MS, true); final String message = eventChecker.verify(WAIT_TIME_MS, true); if (message != null) { if (message != null) { dumpDiagnostics(); dumpDiagnostics(message); checkForAnomaly(); checkForAnomaly(); Assert.fail(formatSystemHealthMessage( Assert.fail(formatSystemHealthMessage( "http://go/tapl : successful gesture produced " + message)); "http://go/tapl : successful gesture produced " + message)); Loading Loading
tests/tapl/com/android/launcher3/tapl/LauncherInstrumentation.java +8 −7 Original line number Original line Diff line number Diff line Loading @@ -450,7 +450,7 @@ public final class LauncherInstrumentation { } } } } dumpDiagnostics(); dumpDiagnostics(message); log("Hierarchy dump for: " + message); log("Hierarchy dump for: " + message); dumpViewHierarchy(); dumpViewHierarchy(); Loading @@ -458,10 +458,11 @@ public final class LauncherInstrumentation { return message; return message; } } private void dumpDiagnostics() { private void dumpDiagnostics(String message) { Log.e("b/156287114", "Input:"); log("Diagnostics for failure: " + message); log("Input:"); logShellCommand("dumpsys input"); logShellCommand("dumpsys input"); Log.e("b/156287114", "TIS:"); log("TIS:"); logShellCommand("dumpsys activity service TouchInteractionService"); logShellCommand("dumpsys activity service TouchInteractionService"); } } Loading @@ -469,10 +470,10 @@ public final class LauncherInstrumentation { try { try { for (String line : mDevice.executeShellCommand(command).split("\\n")) { for (String line : mDevice.executeShellCommand(command).split("\\n")) { SystemClock.sleep(10); SystemClock.sleep(10); Log.d("b/156287114", line); log(line); } } } catch (IOException e) { } catch (IOException e) { Log.d("b/156287114", "Failed to execute " + command); log("Failed to execute " + command); } } } } Loading Loading @@ -1362,7 +1363,7 @@ public final class LauncherInstrumentation { if (mCheckEventsForSuccessfulGestures) { if (mCheckEventsForSuccessfulGestures) { final String message = eventChecker.verify(WAIT_TIME_MS, true); final String message = eventChecker.verify(WAIT_TIME_MS, true); if (message != null) { if (message != null) { dumpDiagnostics(); dumpDiagnostics(message); checkForAnomaly(); checkForAnomaly(); Assert.fail(formatSystemHealthMessage( Assert.fail(formatSystemHealthMessage( "http://go/tapl : successful gesture produced " + message)); "http://go/tapl : successful gesture produced " + message)); Loading