GpsHelper { static public boolean isLimitAdTrackingEnabled(Context context) { final boolean defaultValue = false; if (isPlayServicesAvailable(context)) { return SharedPreferencesHelper.getSharedPreferences(context) .getBoolean(IS_LIMIT_AD_TRACKING_ENABLED_KEY, defaultValue); } else { return defaultValue; } }  static boolean isLimitAdTrackingEnabled(Context context); static void fetchAdvertisingInfoAsync(final Context context, final GpsHelperListener gpsHelperListener); @Deprecated static void setClassNamesForTesting(); static final int GOOGLE_PLAY_SUCCESS_CODE; static final String ADVERTISING_ID_KEY; static final String IS_LIMIT_AD_TRACKING_ENABLED_KEY; }
@Test public void isLimitAdTrackingEnabled_whenGooglePlayServicesIsNotLinked_shouldReturnFalse() throws Exception { assertThat(GpsHelper.isLimitAdTrackingEnabled(context)).isFalse(); }