diff options
2 files changed, 12 insertions, 0 deletions
diff --git a/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/RemoteInputViewTest.java b/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/RemoteInputViewTest.java index 7ab69b043ade..7e1aba57f87b 100644 --- a/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/RemoteInputViewTest.java +++ b/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/RemoteInputViewTest.java @@ -34,6 +34,7 @@ import com.android.systemui.statusbar.ExpandableNotificationRow; import com.android.systemui.statusbar.NotificationTestHelper; import com.android.systemui.statusbar.RemoteInputController; +import org.junit.After; import org.junit.Before; import org.junit.Test; import org.junit.runner.RunWith; @@ -68,6 +69,11 @@ public class RemoteInputViewTest extends SysuiTestCase { mView = RemoteInputView.inflate(mContext, null, row.getEntry(), mController); } + @After + public void tearDown() { + mContext.unregisterReceiver(mReceiver); + } + @Test public void testSendRemoteInput_intentContainsResultsAndSource() throws InterruptedException { PendingIntent pendingIntent = PendingIntent.getBroadcast(mContext, 0, diff --git a/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/SmartReplyViewTest.java b/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/SmartReplyViewTest.java index fc043c56845c..a9b2c96d3ae1 100644 --- a/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/SmartReplyViewTest.java +++ b/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/SmartReplyViewTest.java @@ -37,6 +37,7 @@ import android.widget.LinearLayout; import com.android.systemui.R; import com.android.systemui.SysuiTestCase; +import org.junit.After; import org.junit.Before; import org.junit.Test; import org.junit.runner.RunWith; @@ -76,6 +77,11 @@ public class SmartReplyViewTest extends SysuiTestCase { mSpacing = res.getDimensionPixelSize(R.dimen.smart_reply_button_spacing); } + @After + public void tearDown() { + mContext.unregisterReceiver(mReceiver); + } + @Test public void testSendSmartReply_intentContainsResultsAndSource() throws InterruptedException { setRepliesFromRemoteInput(TEST_CHOICES); |