Beispiel #1
0
 /**
  * Test for False Month Addition
  */
 public function testAddingMonthWhenChangingTimezone()
 {
     $date = new Date(mktime(22, 59, 59, 1, 10, 2009));
     $this->assertEquals(10, $date->toString('d'));
     $this->assertEquals(1, $date->toString('M'));
     $date->setTimezone('Europe/Berlin');
     $date->addMonth(1);
     $this->assertEquals(10, $date->toString('d'));
     $this->assertEquals(2, $date->toString('M'));
 }