public static Point getCenterOfViewOnScreen(View view) {
    int[] location = new int[2];
    view.getLocationOnScreen(location);
    int centerX = location[0] + view.getWidth() / 2;
    int centerY = location[1] + view.getHeight() / 2;
    return new Point(centerX, centerY);
  }
Verifies (with a timeout of {@link #UI_ACTION_EFFECT_TIMEOUT_MILLIS}) that an activity launch
has been attempted and returns the {@link Intent} with which the attempt occurred.

<p><b>NOTE: This method assumes that the {@link DependencyInjector} was configured using {@link
#withLaunchPreventingStartActivityListenerInDependencyResolver()}.</b>
javatests/com/google/android/apps/authenticator/testing/TestUtilities.java