SlashRTest.php 412 B

1234567891011121314151617181920
  1. <?php
  2. namespace Sabre\VObject;
  3. /**
  4. * This issue was pointed out in Issue 55. \r should be stripped completely
  5. * when encoding property values.
  6. */
  7. class SlashRTest extends \PHPUnit_Framework_TestCase {
  8. function testEncode() {
  9. $vcal = new Component\VCalendar();
  10. $prop = $vcal->add('test', "abc\r\ndef");
  11. $this->assertEquals("TEST:abc\\ndef\r\n", $prop->serialize());
  12. }
  13. }