test/java/util/Calendar/CldrFormatNamesTest.java

Print this page

        

*** 21,31 **** * questions. */ /* * @test ! * @bug 8004489 8006509 * @summary Unit test for CLDR FormatData resources * @modules java.base/sun.util.locale.provider * @compile -XDignore.symbol.file CldrFormatNamesTest.java * @run main/othervm -Djava.locale.providers=CLDR CldrFormatNamesTest */ --- 21,31 ---- * questions. */ /* * @test ! * @bug 8004489 8006509 8008577 * @summary Unit test for CLDR FormatData resources * @modules java.base/sun.util.locale.provider * @compile -XDignore.symbol.file CldrFormatNamesTest.java * @run main/othervm -Djava.locale.providers=CLDR CldrFormatNamesTest */
*** 61,90 **** }, "calendarname.buddhist", "\u30bf\u30a4\u4ecf\u6559\u66a6", }, { Locale.PRC, ! "field.zone", "\u533a\u57df", "java.time.islamic.DatePatterns", new String[] { "Gy\u5e74M\u6708d\u65e5EEEE", "Gy\u5e74M\u6708d\u65e5", "Gy\u5e74M\u6708d\u65e5", ! "Gyy-MM-dd", }, "calendarname.islamic", "\u4f0a\u65af\u5170\u65e5\u5386", }, { Locale.GERMANY, "field.dayperiod", "Tagesh\u00e4lfte", "java.time.islamic.DatePatterns", new String[] { ! "EEEE d. MMMM y G", "d. MMMM y G", ! "d. MMM y G", ! "d.M.y G", }, "calendarname.islamic", "Islamischer Kalender", }, }; // Islamic calendar symbol names in ar private static final String[] ISLAMIC_MONTH_NAMES = { "\u0645\u062d\u0631\u0645", --- 61,101 ---- }, "calendarname.buddhist", "\u30bf\u30a4\u4ecf\u6559\u66a6", }, { Locale.PRC, ! "field.zone", "\u65f6\u533a", "java.time.islamic.DatePatterns", new String[] { "Gy\u5e74M\u6708d\u65e5EEEE", "Gy\u5e74M\u6708d\u65e5", "Gy\u5e74M\u6708d\u65e5", ! "Gy/M/d", }, "calendarname.islamic", "\u4f0a\u65af\u5170\u65e5\u5386", }, { Locale.GERMANY, "field.dayperiod", "Tagesh\u00e4lfte", "java.time.islamic.DatePatterns", new String[] { ! "EEEE, d. MMMM y G", "d. MMMM y G", ! "dd.MM.y G", ! "dd.MM.yy GGGGG", }, "calendarname.islamic", "Islamischer Kalender", }, + { + Locale.FRANCE, + "field.dayperiod", "cadran", + "java.time.islamic.DatePatterns", new String[] { + "EEEE d MMMM y G", + "d MMMM y G", + "d MMM y G", + "dd/MM/y GGGGG", + }, + "calendarname.islamic", "calendrier musulman", + }, }; // Islamic calendar symbol names in ar private static final String[] ISLAMIC_MONTH_NAMES = { "\u0645\u062d\u0631\u0645",
*** 125,153 **** if (rb.containsKey(key)) { Object value = rb.getObject(key); if (expected instanceof String) { if (!expected.equals(value)) { errors++; ! System.err.printf("error: key='%s', got '%s' expected '%s'%n", ! key, value, expected); } } else if (expected instanceof String[]) { try { if (!Arrays.equals((Object[]) value, (Object[]) expected)) { errors++; ! System.err.printf("error: key='%s', got '%s' expected '%s'%n", key, Arrays.asList((Object[])value), ! Arrays.asList((Object[])expected)); } } catch (Exception e) { errors++; e.printStackTrace(); } } } else { errors++; ! System.err.println("No resource for " + key); } } } // test Islamic calendar names in Arabic --- 136,164 ---- if (rb.containsKey(key)) { Object value = rb.getObject(key); if (expected instanceof String) { if (!expected.equals(value)) { errors++; ! System.err.printf("error: key='%s', got '%s' expected '%s', rb: %s%n", ! key, value, expected, rb); } } else if (expected instanceof String[]) { try { if (!Arrays.equals((Object[]) value, (Object[]) expected)) { errors++; ! System.err.printf("error: key='%s', got '%s' expected '%s', rb: %s%n", key, Arrays.asList((Object[])value), ! Arrays.asList((Object[])expected), rb); } } catch (Exception e) { errors++; e.printStackTrace(); } } } else { errors++; ! System.err.println("No resource for " + key+", rb: "+rb); } } } // test Islamic calendar names in Arabic