diff --git a/jdk/test/java/time/tck/java/time/chrono/TCKChronology.java b/jdk/test/java/time/tck/java/time/chrono/TCKChronology.java index c705f9794ce..363f2b94044 100644 --- a/jdk/test/java/time/tck/java/time/chrono/TCKChronology.java +++ b/jdk/test/java/time/tck/java/time/chrono/TCKChronology.java @@ -148,7 +148,7 @@ public class TCKChronology { @DataProvider(name = "calendarDisplayName") Object[][] data_of_calendarDisplayNames() { return new Object[][] { - {"Hijrah", "Hijrah-umalqura"}, + {"Hijrah", "Islamic Umm al-Qura Calendar"}, {"ISO", "ISO"}, {"Japanese", "Japanese Calendar"}, {"Minguo", "Minguo Calendar"}, diff --git a/jdk/test/java/time/test/java/time/chrono/TestUmmAlQuraChronology.java b/jdk/test/java/time/test/java/time/chrono/TestUmmAlQuraChronology.java index 63e433f7ac4..3e7cce46d1f 100644 --- a/jdk/test/java/time/test/java/time/chrono/TestUmmAlQuraChronology.java +++ b/jdk/test/java/time/test/java/time/chrono/TestUmmAlQuraChronology.java @@ -438,13 +438,13 @@ public class TestUmmAlQuraChronology { // Test to verify the formatted dates @Test(dataProvider="patternMonthNames") public void test_ofPattern(int year, int month, int day, String expected) { - DateTimeFormatter test = DateTimeFormatter.ofPattern("dd G E MMMM yyyy"); + DateTimeFormatter test = DateTimeFormatter.ofPattern("dd G E MMMM yyyy", Locale.US); assertEquals(test.format(HijrahDate.of(year, month, day)), expected); } // Data provider for localized dates @DataProvider(name="chronoDateTimes") - Object[][] data_chronodatetimes() { + Object[][] data_chronodatetimes() { return new Object[][] { {1432, 12, 29, "Safar 1, 1434 AH"}, {1433, 1, 30, "Safar 30, 1434 AH"}, @@ -463,7 +463,7 @@ public class TestUmmAlQuraChronology { hdt = hdt.plus(1, ChronoUnit.HOURS); hdt = hdt.plus(1, ChronoUnit.MINUTES); hdt = hdt.plus(1, ChronoUnit.SECONDS); - DateTimeFormatter df = DateTimeFormatter.ofLocalizedDate(FormatStyle.LONG).withChronology(Chronology.of("Hijrah-umalqura")).withLocale(Locale.forLanguageTag("en-US")); + DateTimeFormatter df = DateTimeFormatter.ofLocalizedDate(FormatStyle.LONG).withChronology(Chronology.of("Hijrah-umalqura")).withLocale(Locale.US); assertEquals(df.format(hdt), expected); }