diff options
| author | 2024-04-05 17:32:12 +0000 | |
|---|---|---|
| committer | 2024-04-05 17:35:43 +0000 | |
| commit | 5aafaa47723ca1aee85565b11a5a32cb1ee26c16 (patch) | |
| tree | bd0c87458f1aea2efb26b2d6a42a2bfdb753b8ac | |
| parent | 8b86c4f574066a530c64c1889a789bb4e29fec62 (diff) | |
Fix local tests that were failing on eng builds because of Log.wtf
Test: atest SystemUITests
Flag: NA
Change-Id: Idf6f5d71517e8b857fbf53e00440517f2f95fa73
2 files changed, 6 insertions, 3 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/ExpandableNotificationRow.java b/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/ExpandableNotificationRow.java index eb6c7b520037..9e0b16cfb312 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/ExpandableNotificationRow.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/ExpandableNotificationRow.java @@ -1767,7 +1767,7 @@ public class ExpandableNotificationRow extends ActivatableNotificationView */ public ExpandableNotificationRow(Context context, AttributeSet attrs) { this(context, attrs, context); - Log.wtf(TAG, "This constructor shouldn't be called"); + Log.e(TAG, "This constructor shouldn't be called"); } /** diff --git a/packages/SystemUI/tests/src/com/android/systemui/statusbar/notification/logging/NotificationMemoryLoggerTest.kt b/packages/SystemUI/tests/src/com/android/systemui/statusbar/notification/logging/NotificationMemoryLoggerTest.kt index 33a838ed5183..4b0b4b89fad4 100644 --- a/packages/SystemUI/tests/src/com/android/systemui/statusbar/notification/logging/NotificationMemoryLoggerTest.kt +++ b/packages/SystemUI/tests/src/com/android/systemui/statusbar/notification/logging/NotificationMemoryLoggerTest.kt @@ -25,6 +25,7 @@ import android.testing.AndroidTestingRunner import android.util.StatsEvent import androidx.test.filters.SmallTest import com.android.systemui.SysuiTestCase +import com.android.systemui.log.assertLogsWtf import com.android.systemui.shared.system.SysUiStatsLog import com.android.systemui.statusbar.notification.collection.NotifPipeline import com.android.systemui.statusbar.notification.collection.NotificationEntryBuilder @@ -133,8 +134,10 @@ class NotificationMemoryLoggerTest : SysuiTestCase() { val pipeline: NotifPipeline = mock() whenever(pipeline.allNotifs).thenThrow(RuntimeException("Something broke!")) val logger = NotificationMemoryLogger(pipeline, statsManager, immediate, bgExecutor) - assertThat(logger.onPullAtom(SysUiStatsLog.NOTIFICATION_MEMORY_USE, mutableListOf())) - .isEqualTo(StatsManager.PULL_SKIP) + assertLogsWtf { + assertThat(logger.onPullAtom(SysUiStatsLog.NOTIFICATION_MEMORY_USE, mutableListOf())) + .isEqualTo(StatsManager.PULL_SKIP) + } } @Test |