diff options
author | Mario <mario@mariovavti.com> | 2019-12-04 10:25:11 +0000 |
---|---|---|
committer | Mario <mario@mariovavti.com> | 2019-12-04 10:25:11 +0000 |
commit | bde429cff649237984903a252ba1a718e6d74f53 (patch) | |
tree | b2b2570159cfb37689e6ce3b96c3b1b988d676cc /vendor/sabre/dav/tests/Sabre/CalDAV/CalendarQueryVAlarmTest.php | |
parent | cc9f41df5f83bcab435d6fb941b5a8f5b1457037 (diff) | |
parent | 4c8d33d1eb2a804aa70a7bc677d6c73d0d94816b (diff) | |
download | volse-hubzilla-4.6.tar.gz volse-hubzilla-4.6.tar.bz2 volse-hubzilla-4.6.zip |
Merge branch '4.6RC'4.6
Diffstat (limited to 'vendor/sabre/dav/tests/Sabre/CalDAV/CalendarQueryVAlarmTest.php')
-rw-r--r-- | vendor/sabre/dav/tests/Sabre/CalDAV/CalendarQueryVAlarmTest.php | 71 |
1 files changed, 35 insertions, 36 deletions
diff --git a/vendor/sabre/dav/tests/Sabre/CalDAV/CalendarQueryVAlarmTest.php b/vendor/sabre/dav/tests/Sabre/CalDAV/CalendarQueryVAlarmTest.php index ca06d8ffa..660832ba4 100644 --- a/vendor/sabre/dav/tests/Sabre/CalDAV/CalendarQueryVAlarmTest.php +++ b/vendor/sabre/dav/tests/Sabre/CalDAV/CalendarQueryVAlarmTest.php @@ -1,17 +1,19 @@ <?php +declare(strict_types=1); + namespace Sabre\CalDAV; use Sabre\VObject; -class CalendarQueryVAlarmTest extends \PHPUnit_Framework_TestCase { - +class CalendarQueryVAlarmTest extends \PHPUnit\Framework\TestCase +{ /** * This test is specifically for a time-range query on a VALARM, contained - * in a VEVENT that's recurring + * in a VEVENT that's recurring. */ - function testValarm() { - + public function testValarm() + { $vcalendar = new VObject\Component\VCalendar(); $vevent = $vcalendar->createComponent('VEVENT'); @@ -23,29 +25,28 @@ class CalendarQueryVAlarmTest extends \PHPUnit_Framework_TestCase { $valarm->TRIGGER = '-P15D'; $vevent->add($valarm); - $vcalendar->add($vevent); $filter = [ - 'name' => 'VCALENDAR', + 'name' => 'VCALENDAR', 'is-not-defined' => false, - 'time-range' => null, - 'prop-filters' => [], - 'comp-filters' => [ + 'time-range' => null, + 'prop-filters' => [], + 'comp-filters' => [ [ - 'name' => 'VEVENT', + 'name' => 'VEVENT', 'is-not-defined' => false, - 'time-range' => null, - 'prop-filters' => [], - 'comp-filters' => [ + 'time-range' => null, + 'prop-filters' => [], + 'comp-filters' => [ [ - 'name' => 'VALARM', + 'name' => 'VALARM', 'is-not-defined' => false, - 'prop-filters' => [], - 'comp-filters' => [], - 'time-range' => [ + 'prop-filters' => [], + 'comp-filters' => [], + 'time-range' => [ 'start' => new \DateTime('2012-05-10'), - 'end' => new \DateTime('2012-05-20'), + 'end' => new \DateTime('2012-05-20'), ], ], ], @@ -73,8 +74,8 @@ class CalendarQueryVAlarmTest extends \PHPUnit_Framework_TestCase { $this->assertFalse($validator->validate($vcalendar, $filter)); } - function testAlarmWayBefore() { - + public function testAlarmWayBefore() + { $vcalendar = new VObject\Component\VCalendar(); $vevent = $vcalendar->createComponent('VEVENT'); @@ -88,25 +89,25 @@ class CalendarQueryVAlarmTest extends \PHPUnit_Framework_TestCase { $vcalendar->add($vevent); $filter = [ - 'name' => 'VCALENDAR', + 'name' => 'VCALENDAR', 'is-not-defined' => false, - 'time-range' => null, - 'prop-filters' => [], - 'comp-filters' => [ + 'time-range' => null, + 'prop-filters' => [], + 'comp-filters' => [ [ - 'name' => 'VEVENT', + 'name' => 'VEVENT', 'is-not-defined' => false, - 'time-range' => null, - 'prop-filters' => [], - 'comp-filters' => [ + 'time-range' => null, + 'prop-filters' => [], + 'comp-filters' => [ [ - 'name' => 'VALARM', + 'name' => 'VALARM', 'is-not-defined' => false, - 'prop-filters' => [], - 'comp-filters' => [], - 'time-range' => [ + 'prop-filters' => [], + 'comp-filters' => [], + 'time-range' => [ 'start' => new \DateTime('2011-12-10'), - 'end' => new \DateTime('2011-12-20'), + 'end' => new \DateTime('2011-12-20'), ], ], ], @@ -116,7 +117,5 @@ class CalendarQueryVAlarmTest extends \PHPUnit_Framework_TestCase { $validator = new CalendarQueryValidator(); $this->assertTrue($validator->validate($vcalendar, $filter)); - } - } |