*/
public void testInheritsFromWithCategory() {
LocaleData localeData =
new LocaleData(localeFactory, Arrays.asList("root", "en", "en_US", "en_US_VARIANT", "ar",
"ar_IQ"));
GwtLocale localeEn = localeFactory.fromString("en");
localeData.addEntry("foo", localeEn, "k1", "v1");
GwtLocale localeEnUs = localeFactory.fromString("en_us");
GwtLocale localeEnUsVariant = localeFactory.fromString("en_us_variant");
GwtLocale localeDefault = localeFactory.getDefault();
assertEquals(localeEn, localeData.inheritsFrom("foo", localeEnUs));
assertEquals(localeEn, localeData.inheritsFrom("foo", localeEnUsVariant));
assertEquals(localeDefault, localeData.inheritsFrom("foo", localeEn));
assertEquals(localeDefault, localeData.inheritsFrom("bar", localeEnUs));
assertEquals(localeDefault, localeData.inheritsFrom("bar", localeEnUsVariant));
GwtLocale localeAr = localeFactory.fromString("ar");
assertEquals(localeDefault, localeData.inheritsFrom("foo", localeAr));
assertEquals(localeDefault, localeData.inheritsFrom("bar", localeAr));
}