5use PHPUnit\Framework\TestCase;
18 $stream = fopen(
'php://memory',
'r+');
31DTSTAMP:20140122T233226Z
32DTSTART:20140101T070000Z
41 while ($object = $objects->getNext()) {
42 $return .= $object->serialize();
44 $this->assertEquals([], VObject\
Reader::read($return)->validate());
71DTSTAMP:20140122T233226Z
80 while ($object = $objects->getNext()) {
81 $return .= $object->serialize();
83 $this->assertNull($object = $objects->getNext());
102DTSTAMP:20140122T233226Z
103DTSTART:20140101T050000Z
110DTSTAMP:20140122T233226Z
111DTSTART:20140101T060000Z
128 while ($object = $objects->getNext()) {
140 $return .= $object->serialize();
141 $expected = str_replace(
"\n",
"\r\n", $expected);
142 $this->assertEquals($expected, $object->serialize());
145 $this->assertEquals([], VObject\
Reader::read($return)->validate());
156DTSTART:20140101T040000Z
157DTSTAMP:20140122T233226Z
167 while ($object = $objects->getNext()) {
168 $return .= $object->serialize();
175 function($item) {
return $item[
'message']; },
178 $this->fail(
'Validation errors: ' . implode(
"\n",
$messages));
191RRULE:FREQ=YEARLY;BYMONTH=3;BYDAY=-1SU
192DTSTART:19810329T020000
198RRULE:FREQ=YEARLY;BYMONTH=10;BYDAY=-1SU
199DTSTART:19961027T030000
208RRULE:FREQ=YEARLY;BYMONTH=3;BYDAY=-1SU
209DTSTART:19810329T010000
215RRULE:FREQ=YEARLY;BYMONTH=10;BYDAY=-1SU
216DTSTART:19961027T020000
226DTSTAMP:20140122T232710Z
227DTSTART:20140101T010000Z
234DTSTAMP:20140122T232710Z
235DTSTART:20140101T020000Z
242DTSTAMP:20140122T232710Z
243DTSTART:20140101T030000Z
262 while ($object = $objects->getNext()) {
274 $expected = str_replace(
"\n",
"\r\n", $expected);
276 $this->assertEquals($expected, $object->serialize());
277 $return .= $object->serialize();
282 $this->assertEquals([], VObject\
Reader::read($return)->validate());
293CREATED:20120605T072109Z
294UID:D6716295-C10F-4B20-82F9-E1A3026C7DCF
295DTEND;VALUE=DATE:20120717
297SUMMARY:Start Vorbereitung
298DTSTART;VALUE=DATE:20120716
299DTSTAMP:20120605T072115Z
302X-WR-ALARMUID:A99EDA6A-35EB-4446-B8BC-CDA3C60C627D
303UID:A99EDA6A-35EB-4446-B8BC-CDA3C60C627D
305X-APPLE-DEFAULT-ALARM:TRUE
306ATTACH;VALUE=URI:Basso
318 while ($object = $objects->getNext()) {
319 $return .= $object->serialize();
An exception for terminatinating execution or to throw for unit testing.
static read($data, $options=0, $charset='UTF-8')
Parses a vCard or iCalendar object, and returns the top component.
testICalendarImportInvalidEvent()
@expectedException Sabre\VObject\ParseException
testICalendarImportMultipleVTIMEZONESAndMultipleValidEvents()
testICalendarImportWithOutVTIMEZONES()
testICalendarImportEventWithoutUID()
testICalendarImportValidEvent()
testICalendarImportMultipleValidEvents()
testICalendarImportWrongType()
@expectedException Sabre\VObject\ParseException
testICalendarImportEndOfData()
const VERSION
Full version number.
$stream
PHP stream implementation.