public static boolean isStrayIntentRemaining() {
    try {
      intended(anyIntent());
      return true;
    } catch (AssertionFailedError expected) {
      return false;
    }
  }
Fails the test if any {@link Intent}s are still floating around after any validated ones have
been consumed.
javatests/com/google/android/apps/authenticator/testing/TestUtilities.java