/**
  * @expectedException \Celest\DateTimeParseException
  */
 public function test_fieldResolvesToChronoZonedDateTime_overrideChrono_wrongChrono()
 {
     $cldt = ThaiBuddhistChronology::INSTANCE()->dateNow()->atTime(LocalTime::NOON())->atZone(self::EUROPE_PARIS());
     $f = (new DateTimeFormatterBuilder())->appendValue(new ResolvingField($cldt))->toFormatter();
     $f = $f->withChronology(MinguoChronology::INSTANCE());
     $f->parse("1234567890");
 }
 function comparisons_LocalDateTime(array $localDates)
 {
     $this->comparisons_LocalDateTime2($localDates, [LocalTime::MIDNIGHT(), LocalTime::of(0, 0, 0, 999999999), LocalTime::of(0, 0, 59, 0), LocalTime::of(0, 0, 59, 999999999), LocalTime::of(0, 59, 0, 0), LocalTime::of(0, 59, 59, 999999999), LocalTime::NOON(), LocalTime::of(12, 0, 0, 999999999), LocalTime::of(12, 0, 59, 0), LocalTime::of(12, 0, 59, 999999999), LocalTime::of(12, 59, 0, 0), LocalTime::of(12, 59, 59, 999999999), LocalTime::of(23, 0, 0, 0), LocalTime::of(23, 0, 0, 999999999), LocalTime::of(23, 0, 59, 0), LocalTime::of(23, 0, 59, 999999999), LocalTime::of(23, 59, 0, 0), LocalTime::of(23, 59, 59, 999999999)]);
 }
Пример #3
0
 public function test_comparisons()
 {
     $this->doTest_comparisons_LocalTime([LocalTime::MIDNIGHT(), LocalTime::of(0, 0, 0, 999999999), LocalTime::of(0, 0, 59, 0), LocalTime::of(0, 0, 59, 999999999), LocalTime::of(0, 59, 0, 0), LocalTime::of(0, 59, 0, 999999999), LocalTime::of(0, 59, 59, 0), LocalTime::of(0, 59, 59, 999999999), LocalTime::NOON(), LocalTime::of(12, 0, 0, 999999999), LocalTime::of(12, 0, 59, 0), LocalTime::of(12, 0, 59, 999999999), LocalTime::of(12, 59, 0, 0), LocalTime::of(12, 59, 0, 999999999), LocalTime::of(12, 59, 59, 0), LocalTime::of(12, 59, 59, 999999999), LocalTime::of(23, 0, 0, 0), LocalTime::of(23, 0, 0, 999999999), LocalTime::of(23, 0, 59, 0), LocalTime::of(23, 0, 59, 999999999), LocalTime::of(23, 59, 0, 0), LocalTime::of(23, 59, 0, 999999999), LocalTime::of(23, 59, 59, 0), LocalTime::of(23, 59, 59, 999999999)]);
 }