public static TimePeriod of(long months, long days, long millis) {
    return new TimePeriod(unsignedInt(months), unsignedInt(days), unsignedInt(millis));
  }
@Test
  void checkAddingToTemporalItems() {
    TimePeriod monthAndTwoDays = TimePeriod.of(1, 2, 0);
    TimePeriod threeMillis = TimePeriod.of(0, 0, 3);
    TimePeriod complexTimePeriod = TimePeriod.of(1, 2, 3);

    LocalDateTime localDateTime = LocalDateTime.of(2001, 2, 3, 4, 5, 6, 7_000_000);
    LocalDate localDate = LocalDate.of(2001, 2, 3);
    LocalTime localTime = LocalTime.of(4, 5, 6, 7_000_000);

    assertEquals(localDateTime.plusMonths(1).plusDays(2), localDateTime.plus(monthAndTwoDays));
    assertEquals(localDateTime.plus(3, MILLIS), localDateTime.plus(threeMillis));
    assertEquals(localDateTime.plusMonths(1).plusDays(2).plus(3, MILLIS), localDateTime.plus(complexTimePeriod));

    assertEquals(localDate.plusMonths(1).plusDays(2), localDate.plus(monthAndTwoDays));

    assertEquals(localTime.plus(3, MILLIS), localTime.plus(threeMillis));

    assertEquals(localDateTime.minusMonths(1).minusDays(2), localDateTime.minus(monthAndTwoDays));
    assertEquals(localDateTime.minus(3, MILLIS), localDateTime.minus(threeMillis));
    assertEquals(localDateTime.minusMonths(1).minusDays(2).minus(3, MILLIS), localDateTime.minus(complexTimePeriod));

    assertEquals(localDate.minusMonths(1).minusDays(2), localDate.minus(monthAndTwoDays));

    assertEquals(localTime.minus(3, MILLIS), localTime.minus(threeMillis));
  }