public function testOneHour() { $ical_event = $this->_getFixture(2); $driver = new Kronolith_Stub_Driver(); $event = new Kronolith_Event_Sql($driver); $event->fromiCalendar($ical_event); $this->assertFalse($event->isAllDay()); }
private function _getFixture($name, $item = 0) { $iCal = new Horde_Icalendar(); $iCal->parsevCalendar(file_get_contents(__DIR__ . '/../fixtures/' . $name)); $components = $iCal->getComponents(); $event = new Kronolith_Event_Sql(new Kronolith_Stub_Driver()); $event->fromiCalendar($components[$item], true); return $event; }