@@ -354,35 +354,39 @@ class LocalDateTimeTest {
354354
355355 @Test
356356 fun non_continuous_month_matches () = assertEquals(
357- expected = stubDatetime.copy(monthNumber = 5 ),
357+ expected = LocalDateTime (year = 2023 , month = 5 , day = 1 , hour = 0 , minute = 0 , second = 0 ),
358358 actual = stubDatetime.copy(monthNumber = 2 ).nextMatch {
359359 inMonths(Month (1 ), Month (5 ), Month (10 ))
360360 },
361361 )
362362
363363 @Test
364364 fun non_continuous_month_unsorted_matches () = assertEquals(
365- expected = stubDatetime.copy(monthNumber = 5 ),
365+ expected = LocalDateTime (year = 2023 , month = 5 , day = 1 , hour = 0 , minute = 0 , second = 0 ),
366366 actual = stubDatetime.copy(monthNumber = 2 ).nextMatch {
367367 inMonths(Month (10 ), Month (5 ), Month (1 ))
368368 },
369369 )
370370
371371 @Test
372372 fun non_continuous_match_complicated () = assertEquals(
373- expected = stubDatetime.copy(
374- monthNumber = 5 ,
375- dayOfMonth = 5 ,
376- hour = 5 ,
377- minute = 5 ,
378- second = 5 ,
373+ expected = LocalDateTime (
374+ year = 2023 ,
375+ month = 5 ,
376+ day = 1 ,
377+ hour = 0 ,
378+ minute = 0 ,
379+ second = 0 ,
380+ nanosecond = 0
379381 ),
380- actual = stubDatetime.copy(
381- monthNumber = 2 ,
382- dayOfMonth = 2 ,
382+ actual = LocalDateTime (
383+ year = 2023 ,
384+ month = 2 ,
385+ day = 2 ,
383386 hour = 2 ,
384387 minute = 2 ,
385388 second = 2 ,
389+ nanosecond = 0 ,
386390 ).nextMatch {
387391 inMonths(Month (10 ), Month (5 ), Month (1 ))
388392 onDaysOfMonth(10 , 5 , 1 )
@@ -411,10 +415,10 @@ class LocalDateTimeTest {
411415
412416 @Test
413417 fun schedules_day_of_week_multiple_values () = assertEquals(
414- expected = stubDatetime.copy(dayOfMonth = 5 ), // Thursday.
418+ expected = LocalDateTime (year = 2023 , month = 10 , day = 5 , hour = 0 , minute = 0 , second = 0 ), // Thursday.
415419 actual = stubDatetime.nextMatch {
416420 // stubDatetime is October 4th, 2023; a Wednesday.
417- onDaysOfWeek(DayOfWeek .MONDAY .. DayOfWeek .FRIDAY )
421+ onDaysOfWeek(DayOfWeek .MONDAY , DayOfWeek . TUESDAY , DayOfWeek .THURSDAY )
418422 atHours(0 )
419423 atMinutes(0 )
420424 atSeconds(0 )
0 commit comments