comparison vendor/sabre/vobject/tests/VObject/Property/ICalendar/DurationTest.php @ 7:430dbd5346f7

vendor sabre as distributed
author Charlie Root
date Sat, 13 Jan 2018 09:06:10 -0500
parents
children
comparison
equal deleted inserted replaced
6:cec75ba50afc 7:430dbd5346f7
1 <?php
2
3 namespace Sabre\VObject\Property\ICalendar;
4
5 use Sabre\VObject\Component\VCalendar;
6 use Sabre\VObject\Component\VEvent;
7
8 class DurationTest extends \PHPUnit_Framework_TestCase {
9
10 function testGetDateInterval() {
11
12 $vcal = new VCalendar();
13 $event = $vcal->add('VEVENT', array('DURATION' => array('PT1H')));
14
15 $this->assertEquals(
16 new \DateInterval('PT1H'),
17 $event->{'DURATION'}->getDateInterval()
18 );
19 }
20 }