Mercurial > hg > rc1
comparison vendor/sabre/vobject/tests/VObject/EmptyValueIssueTest.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; | |
4 | |
5 /** | |
6 * This test is written for Issue 68: | |
7 * | |
8 * https://github.com/fruux/sabre-vobject/issues/68 | |
9 */ | |
10 class EmptyValueIssueTest extends \PHPUnit_Framework_TestCase { | |
11 | |
12 function testDecodeValue() { | |
13 | |
14 $input = <<<ICS | |
15 BEGIN:VCALENDAR | |
16 VERSION:2.0 | |
17 BEGIN:VEVENT | |
18 DESCRIPTION:This is a descpription\\nwith a linebreak and a \\; \\, and : | |
19 END:VEVENT | |
20 END:VCALENDAR | |
21 ICS; | |
22 | |
23 $vobj = Reader::read($input); | |
24 | |
25 // Before this bug was fixed, getValue() would return nothing. | |
26 $this->assertEquals("This is a descpription\nwith a linebreak and a ; , and :", $vobj->VEVENT->DESCRIPTION->getValue()); | |
27 | |
28 } | |
29 | |
30 } | |
31 |