[Pkg-owncloud-commits] [php-sabre-vobject] 183/341: Add Example 1 of RFC651.
David Prévot
taffit at moszumanska.debian.org
Tue Aug 11 13:35:46 UTC 2015
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository php-sabre-vobject.
commit 073b5248a07026844c2f2047395fc52165b8c15e
Author: Ivan Enderlin <ivan.enderlin at hoa-project.net>
Date: Wed Jan 21 16:17:53 2015 +0100
Add Example 1 of RFC651.
---
tests/VObject/Parser/XmlTest.php | 42 ++++++++++++++++++++++++++++++++++++++++
1 file changed, 42 insertions(+)
diff --git a/tests/VObject/Parser/XmlTest.php b/tests/VObject/Parser/XmlTest.php
index a462dc4..870c373 100644
--- a/tests/VObject/Parser/XmlTest.php
+++ b/tests/VObject/Parser/XmlTest.php
@@ -1109,6 +1109,48 @@ XML
}
+ function testRFC6351Example1() {
+
+ $this->assertXMLEqualsToMimeDir(
+<<<XML
+<?xml version="1.0" encoding="UTF-8"?>
+<vcards xmlns="urn:ietf:params:xml:ns:vcard-4.0">
+ <vcard>
+ <fn>
+ <text>J. Doe</text>
+ </fn>
+ <n>
+ <surname>Doe</surname>
+ <given>J.</given>
+ <additional/>
+ <prefix/>
+ <suffix/>
+ </n>
+ <x-file>
+ <parameters>
+ <mediatype>
+ <text>image/jpeg</text>
+ </mediatype>
+ </parameters>
+ <unknown>alien.jpg</unknown>
+ </x-file>
+ <a xmlns="http://www.w3.org/1999/xhtml" href="http://www.example.com">My web page!</a>
+ </vcard>
+</vcards>
+XML
+,
+ 'BEGIN:VCARD' . CRLF .
+ 'VERSION:4.0' . CRLF .
+ 'FN:J. Doe' . CRLF .
+ 'N:Doe;J.;;;' . CRLF .
+ 'X-FILE;MEDIATYPE=image/jpeg:alien.jpg' . CRLF .
+ 'XML:<a xmlns="http://www.w3.org/1999/xhtml" href="http://www.example.com">M' . CRLF .
+ ' y web page!</a>' . CRLF .
+ 'END:VCARD' . CRLF
+ );
+
+ }
+
/**
* Check this equality:
* XML -> object model -> MIME Dir.
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/php-sabre-vobject.git
More information about the Pkg-owncloud-commits
mailing list