@@ -189,10 +189,6 @@ describe('ZonedDateTime', () => {
189
189
equal ( zdt . toInstant ( ) . epochSeconds , Math . floor ( Date . UTC ( 1976 , 10 , 18 , 15 , 23 , 30 , 123 ) / 1e3 ) , 'epochSeconds' ) ;
190
190
equal ( zdt . toInstant ( ) . epochMilliseconds , Date . UTC ( 1976 , 10 , 18 , 15 , 23 , 30 , 123 ) , 'epochMilliseconds' ) ;
191
191
} ) ;
192
- it ( 'Temporal.ZonedDateTime.from(zonedDateTime) is not the same object)' , ( ) => {
193
- const zdt = new ZonedDateTime ( epochNanos , tz ) ;
194
- notEqual ( ZonedDateTime . from ( zdt ) , zdt ) ;
195
- } ) ;
196
192
197
193
describe ( 'ZonedDateTime for (1976, 11, 18, 15, 23, 30, 123, 456, 789)' , ( ) => {
198
194
const zdt = new ZonedDateTime ( epochNanos , new Temporal . TimeZone ( 'UTC' ) ) ;
@@ -311,12 +307,6 @@ describe('ZonedDateTime', () => {
311
307
const zdt = ZonedDateTime . from ( '2020-03-08T09:00:00Z[America/Los_Angeles]' ) ;
312
308
equal ( zdt . toString ( ) , '2020-03-08T01:00:00-08:00[America/Los_Angeles]' ) ;
313
309
} ) ;
314
- it ( 'ZonedDateTime.from(ISO string leap second) is constrained' , ( ) => {
315
- equal (
316
- `${ ZonedDateTime . from ( '2016-12-31T23:59:60-08:00[America/Vancouver]' ) } ` ,
317
- '2016-12-31T23:59:59-08:00[America/Vancouver]'
318
- ) ;
319
- } ) ;
320
310
it ( 'variant time separators' , ( ) => {
321
311
[ '1976-11-18t15:23-08:00[America/Los_Angeles]' , '1976-11-18 15:23-08:00[America/Los_Angeles]' ] . forEach ( ( input ) =>
322
312
equal ( `${ ZonedDateTime . from ( input ) } ` , '1976-11-18T15:23:00-08:00[America/Los_Angeles]' )
@@ -613,10 +603,6 @@ describe('ZonedDateTime', () => {
613
603
throws ( ( ) => ZonedDateTime . from ( { year : 2019 , month : 1 , day : 1 , timeZone : lagos } , { overflow } ) , RangeError ) ;
614
604
} ) ;
615
605
} ) ;
616
- const leap = { year : 2016 , month : 12 , day : 31 , hour : 23 , minute : 59 , second : 60 , timeZone : lagos } ;
617
- it ( 'reject leap second' , ( ) => throws ( ( ) => ZonedDateTime . from ( leap , { overflow : 'reject' } ) , RangeError ) ) ;
618
- it ( 'constrain leap second' , ( ) =>
619
- equal ( `${ ZonedDateTime . from ( leap ) } ` , '2016-12-31T23:59:59+01:00[Africa/Lagos]' ) ) ;
620
606
} ) ;
621
607
describe ( 'Offset option' , ( ) => {
622
608
it ( "{ offset: 'reject' } throws if offset does not match offset time zone" , ( ) => {
0 commit comments