### Question:
LocaleHelper { @Nonnull @ReturnsImmutableObject @CodingStyleguideUnaware public static List <Locale> getCalculatedLocaleListForResolving (@Nonnull final Locale aLocale) { ValueEnforcer.notNull (aLocale, "Locale"); return s_aLocaleListCache.getFromCache (aLocale); } private  LocaleHelper(); @Nonnull static String getLocaleDisplayName(@Nullable final Locale aLocale, @Nonnull final Locale aContentLocale); @Nonnull static String getLocaleNativeDisplayName(@Nonnull final Locale aLocale); @Nonnull @ReturnsMutableCopy static ICommonsMap <Locale, String> getAllLocaleDisplayNames(@Nonnull final Locale aContentLocale); @Nonnull @ReturnsImmutableObject @CodingStyleguideUnaware static List <Locale> getCalculatedLocaleListForResolving(@Nonnull final Locale aLocale); @Nonnull static Locale getLocaleFromString(@Nullable final String sLocaleAsString); @Nullable static Locale getLocaleToUseOrNull(@Nonnull final Locale aRequestLocale, @Nonnull final Collection <Locale> aAvailableLocales); @Nullable static Locale getLocaleToUseOrFallback(@Nonnull final Locale aRequestLocale,
                                                 @Nonnull final Collection <Locale> aAvailableLocales,
                                                 @Nullable final Locale aFallback); static boolean isSpecialLocale(@Nullable final Locale aLocale); static boolean isSpecialLocaleCode(@Nullable final String sLocale); @Nullable static String getValidLanguageCode(@Nullable final String sCode); @Nullable static String getValidCountryCode(@Nullable final String sCode); @Nonnull static EChange clearCache(); static final char LOCALE_SEPARATOR; static final String STR_ALL; static final Locale LOCALE_ALL; static final String STR_INDEPENDENT; static final Locale LOCALE_INDEPENDENT; }### Answer:
@Test public void testGetCalculatedLocaleListForResolving () { try { LocaleHelper.getCalculatedLocaleListForResolving (null); fail (); } catch (final NullPointerException ex) {} List <Locale> aList = LocaleHelper.getCalculatedLocaleListForResolving (new Locale ("")); assertNotNull (aList); assertEquals (0, aList.size ()); aList = LocaleHelper.getCalculatedLocaleListForResolving (LocaleCache.getInstance ().getLocale ("de")); assertNotNull (aList); assertEquals (1, aList.size ()); assertEquals (LocaleCache.getInstance ().getLocale ("de"), aList.get (0)); aList = LocaleHelper.getCalculatedLocaleListForResolving (LocaleCache.getInstance ().getLocale ("de", "AT")); assertNotNull (aList); assertEquals (2, aList.size ()); assertEquals (LocaleCache.getInstance ().getLocale ("de", "AT"), aList.get (0)); assertEquals (LocaleCache.getInstance ().getLocale ("de"), aList.get (1)); aList = LocaleHelper.getCalculatedLocaleListForResolving (LocaleCache.getInstance ().getLocale ("de", "AT", "Wien")); assertNotNull (aList); assertEquals (3, aList.size ()); assertEquals (LocaleCache.getInstance ().getLocale ("de", "AT", "Wien"), aList.get (0)); assertEquals (LocaleCache.getInstance ().getLocale ("de", "AT"), aList.get (1)); assertEquals (LocaleCache.getInstance ().getLocale ("de"), aList.get (2)); aList = LocaleHelper.getCalculatedLocaleListForResolving (new Locale ("", "AT")); assertNotNull (aList); assertEquals (0, aList.size ()); aList = LocaleHelper.getCalculatedLocaleListForResolving (new Locale ("", "AT", "Wien")); assertNotNull (aList); assertEquals (0, aList.size ()); }