From efc3c4641946804ceabff44f78bc38230d0e2a55 Mon Sep 17 00:00:00 2001 From: Sunny Goyal Date: Tue, 9 Apr 2024 17:03:43 -0700 Subject: [PATCH] Fixing null check causing test breakage Bug: 333609600 Test: Presubmit Flag: None Change-Id: Ic44df00ba945c79010c2cf99a034cca2b5d6c161 --- .../android/launcher3/allapps/PrivateProfileManagerTest.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/src/com/android/launcher3/allapps/PrivateProfileManagerTest.java b/tests/src/com/android/launcher3/allapps/PrivateProfileManagerTest.java index 8f398a66ff..2dcbda4ab6 100644 --- a/tests/src/com/android/launcher3/allapps/PrivateProfileManagerTest.java +++ b/tests/src/com/android/launcher3/allapps/PrivateProfileManagerTest.java @@ -209,7 +209,8 @@ public class PrivateProfileManagerTest { Mockito.verify(mContext).startActivity(acIntent.capture()); assertEquals("Intent Action is different", - expectedIntent.toUri(0), acIntent.getValue().toUri(0)); + expectedIntent == null ? null : expectedIntent.toUri(0), + acIntent.getValue() == null ? null : acIntent.getValue().toUri(0)); } private static void awaitTasksCompleted() throws Exception {