@@ -1325,35 +1325,24 @@ TEST(TimeZoneEdgeCase, AmericaJamaica) {
13251325 ExpectTime (tp, tz, 1983 , 12 , 31 , 23 , 59 , 59 , -5 * 3600 , false , " EST" );
13261326}
13271327
1328- TEST (TimeZoneEdgeCase, WET) {
1329- // Cover some non-existent times within forward transitions.
1330- const time_zone tz = LoadZone (" WET" );
1331-
1332- // Before the first transition.
1333- auto tp = convert (civil_second (1977 , 1 , 1 , 0 , 0 , 0 ), tz);
1334- ExpectTime (tp, tz, 1977 , 1 , 1 , 0 , 0 , 0 , 0 , false , " WET" );
1335-
1336- // Over the first transition.
1337- // 228877199 == Sun, 3 Apr 1977 00:59:59 +0000 (WET)
1338- // 228877200 == Sun, 3 Apr 1977 02:00:00 +0100 (WEST)
1339- tp = convert (civil_second (1977 , 4 , 3 , 0 , 59 , 59 ), tz);
1340- ExpectTime (tp, tz, 1977 , 4 , 3 , 0 , 59 , 59 , 0 , false , " WET" );
1328+ TEST (TimeZoneEdgeCase, EuropeLisbon) {
1329+ // Cover a non-existent time within a forward transition.
1330+ const time_zone tz = LoadZone (" Europe/Lisbon" );
1331+
1332+ // Over a forward transition.
1333+ // 354671999 == Sat, 28 Mar 1981 23:59:59 +0000 (WET)
1334+ // 354672000 == Sun, 29 Mar 1981 01:00:00 +0100 (WEST)
1335+ auto tp = convert (civil_second (1981 , 3 , 28 , 23 , 59 , 59 ), tz);
1336+ ExpectTime (tp, tz, 1981 , 3 , 28 , 23 , 59 , 59 , 0 , false , " WET" );
13411337 tp += cctz::seconds (1 );
1342- ExpectTime (tp, tz, 1977 , 4 , 3 , 2 , 0 , 0 , 1 * 3600 , true , " WEST" );
1338+ ExpectTime (tp, tz, 1981 , 3 , 29 , 1 , 0 , 0 , 1 * 3600 , true , " WEST" );
13431339
1344- // A non-existent time within the first transition.
1345- time_zone::civil_lookup cl1 = tz.lookup (civil_second (1977 , 4 , 3 , 1 , 15 , 0 ));
1340+ // A non-existent time within the transition.
1341+ time_zone::civil_lookup cl1 = tz.lookup (civil_second (1981 , 3 , 29 , 0 , 15 , 0 ));
13461342 EXPECT_EQ (time_zone::civil_lookup::SKIPPED, cl1.kind );
1347- ExpectTime (cl1.pre , tz, 1977 , 4 , 3 , 2 , 15 , 0 , 1 * 3600 , true , " WEST" );
1348- ExpectTime (cl1.trans , tz, 1977 , 4 , 3 , 2 , 0 , 0 , 1 * 3600 , true , " WEST" );
1349- ExpectTime (cl1.post , tz, 1977 , 4 , 3 , 0 , 15 , 0 , 0 * 3600 , false , " WET" );
1350-
1351- // A non-existent time within the second forward transition.
1352- time_zone::civil_lookup cl2 = tz.lookup (civil_second (1978 , 4 , 2 , 1 , 15 , 0 ));
1353- EXPECT_EQ (time_zone::civil_lookup::SKIPPED, cl2.kind );
1354- ExpectTime (cl2.pre , tz, 1978 , 4 , 2 , 2 , 15 , 0 , 1 * 3600 , true , " WEST" );
1355- ExpectTime (cl2.trans , tz, 1978 , 4 , 2 , 2 , 0 , 0 , 1 * 3600 , true , " WEST" );
1356- ExpectTime (cl2.post , tz, 1978 , 4 , 2 , 0 , 15 , 0 , 0 * 3600 , false , " WET" );
1343+ ExpectTime (cl1.pre , tz, 1981 , 3 , 29 , 1 , 15 , 0 , 1 * 3600 , true , " WEST" );
1344+ ExpectTime (cl1.trans , tz, 1981 , 3 , 29 , 1 , 0 , 0 , 1 * 3600 , true , " WEST" );
1345+ ExpectTime (cl1.post , tz, 1981 , 3 , 28 , 23 , 15 , 0 , 0 * 3600 , false , " WET" );
13571346}
13581347
13591348TEST (TimeZoneEdgeCase, FixedOffsets) {
0 commit comments