}
public void testLocaleConfigManager() throws Exception
{
//-------------------default locale is English-------------
LocaleConfig locale = service_.getDefaultLocaleConfig();
assertTrue("expect defautl locale config is found", locale != null);
assertTrue("expect default locale is English", locale.getLocale().equals(Locale.ENGLISH));
// --------------get a locale------------------
locale = service_.getLocaleConfig("fr");
assertTrue("expect locale config is found", locale != null);
assertTrue("expect France locale is found", locale.getLocale().equals(Locale.FRENCH));
locale = service_.getLocaleConfig("vi");
assertTrue("expect locale config is found", locale != null);
assertEquals("expect Viet Nam locale is found", "vi", locale.getLocale().toString());
/*-------------------get all locale config-------------------
* 4 preconfig locales: English, France, Arabic, Vietnamese
**/
Collection<LocaleConfig> locales = service_.getLocalConfigs();
assertTrue(locales.size() == 4);