Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1b0445df authored by Vadim Tryshev's avatar Vadim Tryshev Committed by Android (Google) Code Review
Browse files

Merge "Tuning system health diags" into ub-launcher3-qt-r1-dev

parents 2cccb134 98193241
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -331,8 +331,10 @@ public final class LauncherInstrumentation {

        final String systemHealth = getSystemHealthMessage();
        if (systemHealth != null) {
            message = message + ", which might be a consequence of system health problems:\n<<<\n"
                    + systemHealth + "\n>>>";
            message = message
                    + ", which might be a consequence of system health "
                    + "problems:\n<<<<<<<<<<<<<<<<<<\n"
                    + systemHealth + "\n>>>>>>>>>>>>>>>>>>";
        }

        log("Hierarchy dump for: " + message);
+4 −2
Original line number Diff line number Diff line
@@ -109,6 +109,7 @@ public class TestHelpers {
        DropBoxManager.Entry entry;
        StringBuilder errorDetails = new StringBuilder();
        while (null != (entry = dropbox.getNextEntry(label, timestamp))) {
            if (errorDetails.length() != 0) errorDetails.append("------------------------------");
            timestamp = entry.getTimeMillis();
            errorDetails.append(new Date(timestamp));
            errorDetails.append(": ");
@@ -135,7 +136,6 @@ public class TestHelpers {
                    "system_server_crash",
                    "system_server_native_crash",
                    "system_server_watchdog",
                    "system_server_wtf",
            };

            for (String label : labels) {
@@ -143,7 +143,9 @@ public class TestHelpers {
                if (crash != null) errors.append(crash);
            }

            return errors.length() != 0 ? errors.toString() : null;
            return errors.length() != 0
                    ? "Current time: " + new Date(System.currentTimeMillis()) + "\n" + errors
                    : null;
        } catch (Exception e) {
            return "Failed to get system health diags, maybe build your test via .bp instead of "
                    + ".mk? " + android.util.Log.getStackTraceString(e);