public function testSetDay() { $dotm = new DayOfTheMonth(20); $this->assertEquals(20, $dotm->getDay()); $dotm->setDay(21); $this->assertEquals(21, $dotm->getDay()); }
/** * Whether the $datetime is * * @param DateTime $dateTime * * @return boolean */ protected function onMonthDays(DateTime $dateTime) { if (!$this->monthDays->count()) { return true; } $dotm = new DayOfTheMonth(); while ($this->monthDays->next()) { if ($dotm->setDay($this->monthDays->current())->contains($dateTime)) { return true; } } return false; }