@Override
  public void destroy() {
    mCurrentRunningLocalProxy.dispose();
    mContext.unregisterReceiver(mMediaInsertionAvailableReceiver);
  }
@Test
  public void testReceiverLifeCycle() {
    Assert.assertEquals(
        1,
        mShadowApplication.getRegisteredReceivers().stream()
            .filter(
                wrapper ->
                    wrapper.broadcastReceiver
                        instanceof RemoteInsertionImpl.MediaInsertionAvailableReceiver)
            .count());

    mUnderTest.destroy();
    Assert.assertEquals(
        0,
        mShadowApplication.getRegisteredReceivers().stream()
            .filter(
                wrapper ->
                    wrapper.broadcastReceiver
                        instanceof RemoteInsertionImpl.MediaInsertionAvailableReceiver)
            .count());
  }