From: Yoshito Umaoka Date: Mon, 11 Aug 2014 21:11:48 +0000 (+0000) Subject: ICU-10898 tzdata2014f updates to ICU4J X-Git-Tag: milestone-59-0-1~1749 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=4f4f553c751b005ea5811aa2ef93f201fc9ca974;p=icu ICU-10898 tzdata2014f updates to ICU4J X-SVN-Rev: 36139 --- diff --git a/icu4j/main/shared/data/icutzdata.jar b/icu4j/main/shared/data/icutzdata.jar index 5d693364fed..51a35e20315 100755 --- a/icu4j/main/shared/data/icutzdata.jar +++ b/icu4j/main/shared/data/icutzdata.jar @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d3137adf135a24c2bb8f5fcbbbdea86e07a79f3eb8f4dab3734e88afa7a2dc7a -size 91046 +oid sha256:b7a225ee1ed42c0dab0082b046e3be1b2f81d49d866bacd3115aa0b7627b7e4d +size 90848 diff --git a/icu4j/main/tests/core/src/com/ibm/icu/dev/test/format/DateFormatTest.java b/icu4j/main/tests/core/src/com/ibm/icu/dev/test/format/DateFormatTest.java index 939e3daae50..5e878a201e9 100644 --- a/icu4j/main/tests/core/src/com/ibm/icu/dev/test/format/DateFormatTest.java +++ b/icu4j/main/tests/core/src/com/ibm/icu/dev/test/format/DateFormatTest.java @@ -860,8 +860,8 @@ public class DateFormatTest extends com.ibm.icu.dev.test.TestFmwk { { "en", "Asia/Calcutta", "2004-07-15T00:00:00Z", "vvvv", "India Standard Time", "Asia/Calcutta" }, // Proper CLDR primary zone support #9733 - { "en", "Asia/Shanghai", "2013-01-01T00:00:00Z", "VVVV", "China Time", "Asia/Shanghai" }, - { "en", "Asia/Harbin", "2013-01-01T00:00:00Z", "VVVV", "Harbin Time", "Asia/Harbin" }, + { "en", "America/Santiago", "2013-01-01T00:00:00Z", "VVVV", "Chile Time", "America/Santiago" }, + { "en", "Pacific/Easter", "2013-01-01T00:00:00Z", "VVVV", "Easter Time", "Pacific/Easter" }, // ========== @@ -1073,10 +1073,6 @@ public class DateFormatTest extends com.ibm.icu.dev.test.TestFmwk { { "zh", "Asia/Calcutta", "2004-07-15T00:00:00Z", "v", "\u5370\u5ea6\u65f6\u95f4", "Asia/Calcutta" }, { "zh", "Asia/Calcutta", "2004-07-15T00:00:00Z", "vvvv", "\u5370\u5EA6\u65f6\u95f4", "Asia/Calcutta" }, - // Proper CLDR primary zone support #9733 - { "zh", "Asia/Shanghai", "2013-01-01T00:00:00Z", "VVVV", "\u4e2d\u56fd\u65f6\u95f4", "Asia/Shanghai" }, - { "zh", "Asia/Harbin", "2013-01-01T00:00:00Z", "VVVV", "\u54c8\u5c14\u6ee8\u65f6\u95f4", "Asia/Harbin" }, - // ========== { "hi", "America/Los_Angeles", "2004-01-15T00:00:00Z", "Z", "-0800", "-8:00" }, @@ -3707,7 +3703,7 @@ public class DateFormatTest extends com.ibm.icu.dev.test.TestFmwk { GregorianCalendar gcal = new GregorianCalendar(tz); gcal.clear(); - gcal.set(1910, Calendar.JANUARY, 1, 12, 00); // offset 8:05:57 + gcal.set(1900, Calendar.JANUARY, 1, 12, 00); // offset 8:05:43 d1 = gcal.getTime(); gcal.clear(); @@ -3717,7 +3713,7 @@ public class DateFormatTest extends com.ibm.icu.dev.test.TestFmwk { gcal.clear(); gcal.set(1970, Calendar.JANUARY, 1, 12, 00); dexp2 = gcal.getTime(); - dexp1 = new Date(dexp2.getTime() - (5*60 + 57)*1000); // subtract 5m57s + dexp1 = new Date(dexp2.getTime() - (5*60 + 43)*1000); // subtract 5m43s DateFormat fmt = DateFormat.getTimeInstance(DateFormat.FULL, new ULocale("zh")); fmt.setTimeZone(tz); diff --git a/icu4j/main/tests/core/src/com/ibm/icu/dev/test/format/TimeZoneFormatTest.java b/icu4j/main/tests/core/src/com/ibm/icu/dev/test/format/TimeZoneFormatTest.java index a1114076d63..545b59974b8 100644 --- a/icu4j/main/tests/core/src/com/ibm/icu/dev/test/format/TimeZoneFormatTest.java +++ b/icu4j/main/tests/core/src/com/ibm/icu/dev/test/format/TimeZoneFormatTest.java @@ -398,6 +398,11 @@ public class TimeZoneFormatTest extends com.ibm.icu.dev.test.TestFmwk { } } + if (id.equals("Pacific/Apia") && PATTERNS[patidx].equals("vvvv") + && logKnownIssue("11052", "Ambiguous zone name - Samoa Time")) { + continue; + } + BasicTimeZone btz = (BasicTimeZone)TimeZone.getTimeZone(id, TimeZone.TIMEZONE_ICU); TimeZone tz = TimeZone.getTimeZone(id); sdf.setTimeZone(tz); @@ -458,7 +463,8 @@ public class TimeZoneFormatTest extends com.ibm.icu.dev.test.TestFmwk { .append(", time=").append(testTimes[testidx]) .append(", restime=").append(restime) .append(", diff=").append(timeDiff); - if (expectedRoundTrip[testidx]) { + if (expectedRoundTrip[testidx] + && !isSpecialTimeRoundTripCase(LOCALES[locidx], id, PATTERNS[patidx], testTimes[testidx])) { errln("FAIL: " + msg.toString()); } else if (REALLY_VERBOSE_LOG) { logln(msg.toString()); @@ -497,6 +503,31 @@ public class TimeZoneFormatTest extends com.ibm.icu.dev.test.TestFmwk { logln("Iteration: " + testCounts); } + // Special exclusions in TestTimeZoneRoundTrip. + // These special cases do not round trip time as designed. + private boolean isSpecialTimeRoundTripCase(ULocale loc, String id, String pattern, long time) { + final Object[][] EXCLUSIONS = { + {null, "Asia/Chita", "zzzz", Long.valueOf(1414252800000L)}, + {null, "Asia/Chita", "vvvv", Long.valueOf(1414252800000L)}, + {null, "Asia/Srednekolymsk", "zzzz", Long.valueOf(1414241999999L)}, + {null, "Asia/Srednekolymsk", "vvvv", Long.valueOf(1414241999999L)}, + }; + boolean isExcluded = false; + for (Object[] excl : EXCLUSIONS) { + if (excl[0] == null || loc.equals((ULocale)excl[0])) { + if (id.equals(excl[1])) { + if (excl[2] == null || pattern.equals((String)excl[2])) { + if (excl[3] == null || ((Long)excl[3]).compareTo(time) == 0) { + isExcluded = true; + break; + } + } + } + } + } + return isExcluded; + } + public void TestParse() { final Object[][] DATA = { // text inpos locale style diff --git a/icu4j/main/tests/core/src/com/ibm/icu/dev/test/timezone/TimeZoneTest.java b/icu4j/main/tests/core/src/com/ibm/icu/dev/test/timezone/TimeZoneTest.java index 1982471b158..ea6d21a3a5d 100644 --- a/icu4j/main/tests/core/src/com/ibm/icu/dev/test/timezone/TimeZoneTest.java +++ b/icu4j/main/tests/core/src/com/ibm/icu/dev/test/timezone/TimeZoneTest.java @@ -1475,7 +1475,16 @@ public class TimeZoneTest extends TestFmwk // Some canonical IDs in CLDR are defined as "Link" // in Olson tzdata. final String[][] excluded1 = { + {"Africa/Bamako", "Africa/Abidjan"}, + {"Africa/Banjul", "Africa/Abidjan"}, + {"Africa/Conakry", "Africa/Abidjan"}, + {"Africa/Dakar", "Africa/Abidjan"}, + {"Africa/Freetown", "Africa/Abidjan"}, {"Africa/Khartoum", "Africa/Juba"}, + {"Africa/Lome", "Africa/Abidjan"}, + {"Africa/Nouakchott", "Africa/Abidjan"}, + {"Africa/Ouagadougou", "Africa/Abidjan"}, + {"Africa/Sao_Tome", "Africa/Abidjan"}, {"America/Shiprock", "America/Denver"}, // America/Shiprock is defined as a Link to America/Denver in tzdata {"America/Kralendijk", "America/Curacao"}, {"America/Lower_Princes", "America/Curacao"}, @@ -1499,6 +1508,7 @@ public class TimeZoneTest extends TestFmwk {"America/Lower_Princes", "America/Aruba"}, {"Antarctica/South_Pole", "Antarctica/McMurdo"}, {"Atlantic/Jan_Mayen", "Europe/Oslo"}, + {"Atlantic/St_Helena", "Africa/Abidjan"}, {"Arctic/Longyearbyen", "Europe/Oslo"}, {"Europe/Busingen", "Europe/Zurich"}, {"Europe/Guernsey", "Europe/London"},