summaryrefslogtreecommitdiff
path: root/test/synckolab/parser
diff options
context:
space:
mode:
authorniko <niko>2012-10-06 23:25:33 (GMT)
committerniko <niko>2012-10-06 23:25:33 (GMT)
commit1b345176e3942b5909862878e772bfe83b6c9f94 (patch)
tree93b84269eff1e5d244887d193415ba80f2ab72bd /test/synckolab/parser
parent32c1661206a070f04a15fc024464f91e932aac35 (diff)
downloadsynckolab-1b345176e3942b5909862878e772bfe83b6c9f94.tar.gz
reading of kolab3 format - unit tests
Diffstat (limited to 'test/synckolab/parser')
-rw-r--r--test/synckolab/parser/kolab3/contactTest.js23
-rw-r--r--test/synckolab/parser/kolab3/json/complex.vcf.mime.json42
-rw-r--r--test/synckolab/parser/kolab3/json/simple.vcf.mime.json12
-rw-r--r--test/synckolab/parser/kolab3/raw/complex.ics.mime216
-rw-r--r--test/synckolab/parser/kolab3/raw/complex.task.ics.mime216
-rw-r--r--test/synckolab/parser/kolab3/raw/contacttest-e79e08cc-0f02-11e2-9e3c-000476ed9009.eml100
-rw-r--r--test/synckolab/parser/kolab3/raw/kaltest-2D96EAF4BBB56DBB8A7D0D48122FD0DD-7F0077A606323E46.eml100
-rw-r--r--test/synckolab/parser/kolab3/raw/simple.ics.mime86
-rw-r--r--test/synckolab/parser/kolab3/raw/simple.task.ics.mime70
-rw-r--r--test/synckolab/parser/kolab3/raw/utf8base64.ics.mime54
-rw-r--r--test/synckolab/parser/kolab3/raw/utf8quotedPrintable.ics.mime88
11 files changed, 1005 insertions, 2 deletions
diff --git a/test/synckolab/parser/kolab3/contactTest.js b/test/synckolab/parser/kolab3/contactTest.js
index 3e067ca..8e05dcb 100644
--- a/test/synckolab/parser/kolab3/contactTest.js
+++ b/test/synckolab/parser/kolab3/contactTest.js
@@ -12,9 +12,23 @@ load("test/lib/testOverride.js");
test("synckolab.addressbookTools.parseMessageContent", function(){
equal(null, synckolab.addressbookTools.parseMessageContent(null), "parsing a null message");
+ var testFiles = ["simple.vcf.mime","complex.vcf.mime"];
+
+ var content, entry, jsonEntry;
+
+ for(var i = 0; i < testFiles.length; i++) {
+ var src = testFiles[i];
+
+ content = readFile("test/synckolab/parser/kolab3/raw/"+src);
+ content = synckolab.tools.stripMailHeader(content);
+ entry = synckolab.addressbookTools.parseMessageContent(content);
+ content = readFile("test/synckolab/parser/kolab3/json/"+src+".json");
+ jsonEntry = JSON.parse(content);
+ equal(synckolab.tools.equalsObject(entry, jsonEntry), true, src);
+ }
});
- var testFiles = ["testcontact", "testContactMinimalFromXML"];
+ var testFiles = ["complex.vcf.mime"];
var content, entry, jsonEntry;
@@ -22,12 +36,17 @@ test("synckolab.addressbookTools.parseMessageContent", function(){
for(var i = 0; i < testFiles.length; i++) {
var src = testFiles[i];
- content = readFile("test/synckolab/parser/kolab3/raw/"+src+".xml");
+ content = readFile("test/synckolab/parser/kolab3/raw/"+src);
+ content = synckolab.tools.stripMailHeader(content);
+ print(content);
+ print("==== STARTING PARSE")
entry = synckolab.addressbookTools.parseMessageContent(content);
print(JSON.stringify(entry, null, ' '))
+ /*
content = readFile("test/synckolab/parser/kolab3/json/"+src+".json");
jsonEntry = JSON.parse(content);
equal(synckolab.tools.equalsObject(entry, jsonEntry), true, src);
+ */
}
diff --git a/test/synckolab/parser/kolab3/json/complex.vcf.mime.json b/test/synckolab/parser/kolab3/json/complex.vcf.mime.json
new file mode 100644
index 0000000..e9c7002
--- /dev/null
+++ b/test/synckolab/parser/kolab3/json/complex.vcf.mime.json
@@ -0,0 +1,42 @@
+ {
+ "synckolab": "3.0.0",
+ "type": "contact",
+ "isMailList": false,
+ "ts": 1349565039427,
+ "UUID": "urn:uuid:Huu5X7hfYy",
+ "DisplayName": "Displayname",
+ "FirstName": "Lastname",
+ "LastName": "Firstname",
+ "Notes": "Notes",
+ "title": "Title",
+ "WebPage1": "www.homepage.org",
+ "WebPage2": "www.blog.test",
+ "HomeAddress": "Home Street",
+ "HomeAddress2": "",
+ "HomeCity": "Home Locality",
+ "HomeState": "Home Region",
+ "HomeZipCode": "Home Postal Code",
+ "HomeCountry": "Gabon",
+ "WorkAddress": "Work Street",
+ "WorkAddress2": "",
+ "WorkCity": "Work Locality",
+ "WorkState": "Work Region",
+ "WorkZipCode": "Work Postal Code",
+ "WorkCountry": "Azerbaijan",
+ "NickName": "Nickname",
+ "related": "Partner",
+ "BirthYear": 2009,
+ "BirthMonth": 6,
+ "BirthDay": 27,
+ "AnniversaryYear": 2009,
+ "AnniversaryMonth": 6,
+ "AnniversaryDay": 28,
+ "HomePhone": "+4930-homephone",
+ "CellularNumber": "+4930-mobile",
+ "WorkPhone": "+4930-workphone",
+ "FaxNumber": "+4930-fax",
+ "AimScreenName": "messaging",
+ "PrimaryEmail": "first@email.org",
+ "SecondEmail": "second@email.org",
+ "sha1": "64d8099d65db9198bcb1bca276d88b7a82ffd0eb"
+} \ No newline at end of file
diff --git a/test/synckolab/parser/kolab3/json/simple.vcf.mime.json b/test/synckolab/parser/kolab3/json/simple.vcf.mime.json
new file mode 100644
index 0000000..6e779b9
--- /dev/null
+++ b/test/synckolab/parser/kolab3/json/simple.vcf.mime.json
@@ -0,0 +1,12 @@
+{
+ "synckolab": "3.0.0",
+ "type": "contact",
+ "isMailList": false,
+ "ts": 1349536624864,
+ "UUID": "urn:uuid:4xuyC0cyjV",
+ "DisplayName": "Volker Krause",
+ "FirstName": "Krause",
+ "LastName": "Volker",
+ "PrimaryEmail": "vkrause@kde.org",
+ "sha1": "b93a56ffad8ad756d72ca9aae70f49e4bd85ecb8"
+} \ No newline at end of file
diff --git a/test/synckolab/parser/kolab3/raw/complex.ics.mime b/test/synckolab/parser/kolab3/raw/complex.ics.mime
new file mode 100644
index 0000000..0176c5e
--- /dev/null
+++ b/test/synckolab/parser/kolab3/raw/complex.ics.mime
@@ -0,0 +1,216 @@
+Date: Mon, 23 Apr 2012 12:37:59 +0200
+X-Kolab-Type: application/x-vnd.kolab.event
+X-Kolab-Mime-Version: 3.0
+User-Agent: Libkolab-0.1.0
+Content-Type: multipart/mixed; boundary="nextPart1929983.SbWkbbbi0G"
+Subject: KOrganizer-1687167952.818
+MIME-Version: 1.0
+
+
+--nextPart1929983.SbWkbbbi0G
+Content-Type: text/plain; charset="us-ascii"
+Content-Transfer-Encoding: 7Bit
+
+This is a Kolab Groupware object.
+To view this object you will need an email client that can understand the Kolab Groupware format.
+For a list of such email clients please visit
+http://www.kolab.org/get-kolab
+
+--nextPart1929983.SbWkbbbi0G
+Content-Type: application/calendar+xml; name="kolab.xml"
+Content-Transfer-Encoding: quoted-printable
+Content-Disposition: attachment; filename="kolab.xml"
+
+<?xml version=3D"1.0" encoding=3D"UTF-8" standalone=3D"no" ?>
+<icalendar xmlns=3D"urn:ietf:params:xml:ns:icalendar-2.0">
+
+ <vcalendar>
+ <properties>
+ <prodid>
+ <text>Libkolab-0.1.0 Libkolabxml-0.3.0</text>
+ </prodid>
+ <version>
+ <text>2.0</text>
+ </version>
+ <x-kolab-version>
+ <text>3.0dev1</text>
+ </x-kolab-version>
+ </properties>
+ <components>
+ <vevent>
+ <properties>
+ <uid>
+ <text>KOrganizer-1687167952.818</text>
+ </uid>
+ <created>
+ <date-time>2009-09-01T12:52:58Z</date-time>
+ </created>
+ <dtstamp>
+ <date-time>2012-05-05T05:05:05Z</date-time>
+ </dtstamp>
+ <sequence>
+ <integer>0</integer>
+ </sequence>
+ <class>
+ <text>PRIVATE</text>
+ </class>
+ <categories>
+ <text>Appointment</text>
+ <text>Business</text>
+ </categories>
+ <dtstart>
+ <parameters>
+ <tzid>
+ <text>/kolab.org/Europe/Berlin</text>
+ </tzid>
+ </parameters>
+ <date-time>2009-09-02T10:00:00</date-time>
+ </dtstart>
+ <dtend>
+ <parameters>
+ <tzid>
+ <text>/kolab.org/Europe/Berlin</text>
+ </tzid>
+ </parameters>
+ <date-time>2009-09-02T11:00:00</date-time>
+ </dtend>
+ <transp>
+ <text>TRANSPARENT</text>
+ </transp>
+ <rrule>
+ <recur>
+ <freq>WEEKLY</freq>
+ <count>10</count>
+ <byday>WE</byday>
+ <byday>FR</byday>
+ </recur>
+ </rrule>
+ <exdate>
+ <date>2009-09-04</date>
+ </exdate>
+ <summary>
+ <text>Complex Event</text>
+ </summary>
+ <description>
+ <text>Some notes on this event.</text>
+ </description>
+ <location>
+ <text>Here</text>
+ </location>
+ <attendee>
+ <parameters>
+ <cn>
+ <text>Attendee1</text>
+ </cn>
+ <partstat>
+ <text>NEEDS-ACTION</text>
+ </partstat>
+ <role>
+ <text>REQ-PARTICIPANT</text>
+ </role>
+ <rsvp>
+ <boolean>true</boolean>
+ </rsvp>
+ </parameters>
+ <cal-address>mailto:%3Ca1%40example.com%3E</cal-address>
+ </attendee>
+ <attendee>
+ <parameters>
+ <cn>
+ <text>Attendee2</text>
+ </cn>
+ <partstat>
+ <text>ACCEPTED</text>
+ </partstat>
+ <role>
+ <text>NON-PARTICIPANT</text>
+ </role>
+ <rsvp>
+ <boolean>true</boolean>
+ </rsvp>
+ </parameters>
+ <cal-address>mailto:%3Ca2%40example.com%3E</cal-address>
+ </attendee>
+ <attendee>
+ <parameters>
+ <cn>
+ <text>Attendee3</text>
+ </cn>
+ <partstat>
+ <text>DECLINED</text>
+ </partstat>
+ <role>
+ <text>REQ-PARTICIPANT</text>
+ </role>
+ </parameters>
+ <cal-address>mailto:%3Ca3%40example.com%3E</cal-address>
+ </attendee>
+ <attach>
+ <parameters>
+ <fmttype>
+ <text>image/png</text>
+ </fmttype>
+ <x-label>
+ <text>akonadi.png</text>
+ </x-label>
+ </parameters>
+ <uri>cid:7313173.zaagFSsPPv@kolab.resource.akonadi</uri>
+ </attach>
+ </properties>
+ <components>
+ <valarm>
+ <properties>
+ <action>
+ <text>DISPLAY</text>
+ </action>
+ <description>
+ <text/>
+ </description>
+ <trigger>
+ <parameters>
+ <related>
+ <text>START</text>
+ </related>
+ </parameters>
+ <duration>-PT900S</duration>
+ </trigger>
+ <duration>
+ <duration>PT5S</duration>
+ </duration>
+ <repeat>
+ <integer>0</integer>
+ </repeat>
+ </properties>
+ </valarm>
+ </components>
+ </vevent>
+ </components>
+ </vcalendar>
+
+</icalendar>
+
+--nextPart1929983.SbWkbbbi0G
+Content-ID: <7313173.zaagFSsPPv@kolab.resource.akonadi>
+Content-Type: image/png; name="akonadi.png"
+Content-Transfer-Encoding: base64
+Content-Disposition: attachment; filename="akonadi.png"
+
+iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAAZiS0dEAP8A
+/wD/oL2nkwAAAAlwSFlzAAAbrwAAG68BXhqRHAAAAAd0SU1FB9gFEQkdFPibCIYAAAMrSURBVDjL
+pZNLaBx1AMZ/M/P/78zOzO7ObDbvNUnTxsUUm6YmaulNxN70UKEIRTyIBy8KHrypRUTw4Ek8CqKn
+XuyhHgQRFTRNAvVFbOnDNO/EfWZmdmczszPrwcdBvPnBd/ng98F3+OB/Svl3cPbSx5mZ+ZkXjKx+
+setHs4cHbaW+7d2s79SvhK29j+6vvXH0nwVPfLh1WsTptdnxuDDxoGv3NZWuf4S3G1C722BrrcrO
+nY1f/ebO05s337n3N6cBLLy1bI7njr4uD4nJhx4by5SGLQYcAzWnI6SGVFUkQKwMRqH/jGHNfXJY
+XwoBBMDc/MhLThpOJ6ZEMzM4moquQpIVxI5Br5QlHrEImw5xuzRJ0n4beBlABRgwxcXhUp5Ww6OX
+QvCXo/TPjUJq6FmJldPJOTZ2znj++HOfnwQQ0y9+e67X6iykpmTCNTnY9xBjeTQVelFC0u3RjxNI
++6iaQiajYtmGlXa6NxZe/f4pobv24/X9thBSYebUEHc26zT6kLMkaZTQ84+IvYioE9PrRvTTCBSF
+2PczUTxyVuiOsXHju58Y0XTaQcTJM0OsXt9kaqqIrinEQUTYCPGrAR2vRbcbELS7ZGWEj72hzL+5
+MqS0uzvBys/CzbsUxx0KJROvnTBZLtCPU/y6j1erE/g1wrBNdqREWKwktdB4QP3h8qO/K6Z2RR8b
+JmjtUx7KMDtd4MSozuatXX5Zus3tH29Rre7S18GtjFNanAMpr37w2ti+ABAyeT0eLJ7vtWoDX1z9
+BiXV0DRJmqakSRfd1iiMOmSPjeKeqVC/H3oPT8r3ZNyzVID3L1V2nDzPqsPlQ2PiGKoJCQFJ4qPI
+FH0gh3P6ONlHKlQ3ve6EEb57fl7GSh9DAVjaqmrNRsv97Kv1xeurjcthkCyqURs7JzBdE6NokQgJ
+SbQ+O65+euqEszo4UPytWMhvCwBUkSqq1jk356xNDUevLK/sPbl+L7jQ8ZLyUaepGE1xMDZhfDlb
+KSwPFt1tXcp9qWk1VWjhP2e6dneLvhdqLc/L7B3UzfX1qttsdfKKguo4ZlguO36xWAgLth3mbSsy
+TatnyFz6B+BnWV0A/UiAAAAAAElFTkSuQmCC
+
+--nextPart1929983.SbWkbbbi0G-- \ No newline at end of file
diff --git a/test/synckolab/parser/kolab3/raw/complex.task.ics.mime b/test/synckolab/parser/kolab3/raw/complex.task.ics.mime
new file mode 100644
index 0000000..e52f694
--- /dev/null
+++ b/test/synckolab/parser/kolab3/raw/complex.task.ics.mime
@@ -0,0 +1,216 @@
+Date: Fri, 27 Apr 2012 16:58:49 +0200
+X-Kolab-Type: application/x-vnd.kolab.task
+X-Kolab-Mime-Version: 3.0
+User-Agent: Libkolab-0.2.0
+Content-Type: multipart/mixed; boundary="nextPart1676922.i4WXLoZAWe"
+Subject: KOrganizer-396756838.184
+MIME-Version: 1.0
+
+
+--nextPart1676922.i4WXLoZAWe
+Content-Type: text/plain; charset="us-ascii"
+Content-Transfer-Encoding: 7Bit
+
+This is a Kolab Groupware object.
+To view this object you will need an email client that can understand the Kolab Groupware format.
+For a list of such email clients please visit
+http://www.kolab.org/get-kolab
+
+--nextPart1676922.i4WXLoZAWe
+Content-Type: application/calendar+xml; name="kolab.xml"
+Content-Transfer-Encoding: quoted-printable
+Content-Disposition: attachment; filename="kolab.xml"
+
+<?xml version=3D"1.0" encoding=3D"UTF-8" standalone=3D"no" ?>
+<icalendar xmlns=3D"urn:ietf:params:xml:ns:icalendar-2.0">
+
+ <vcalendar>
+ <properties>
+ <prodid>
+ <text>Libkolab-0.2.0 Libkolabxml-0.4.0</text>
+ </prodid>
+ <version>
+ <text>2.0</text>
+ </version>
+ <x-kolab-version>
+ <text>3.0dev1</text>
+ </x-kolab-version>
+ </properties>
+ <components>
+ <vtodo>
+ <properties>
+ <uid>
+ <text>KOrganizer-396756838.184</text>
+ </uid>
+ <created>
+ <date-time>2009-09-01T13:39:15Z</date-time>
+ </created>
+ <dtstamp>
+ <date-time>2012-05-05T05:05:05Z</date-time>
+ </dtstamp>
+ <sequence>
+ <integer>0</integer>
+ </sequence>
+ <class>
+ <text>PRIVATE</text>
+ </class>
+ <categories>
+ <text>Business</text>
+ <text>Education</text>
+ </categories>
+ <dtstart>
+ <parameters>
+ <tzid>
+ <text>/kolab.org/Europe/Berlin</text>
+ </tzid>
+ </parameters>
+ <date-time>2009-09-01T16:00:00</date-time>
+ </dtstart>
+ <due>
+ <parameters>
+ <tzid>
+ <text>/kolab.org/Europe/Berlin</text>
+ </tzid>
+ </parameters>
+ <date-time>2009-09-08T16:00:00</date-time>
+ </due>
+ <recurrence-id>
+ <parameters>
+ <tzid>
+ <text>/kolab.org/Europe/Berlin</text>
+ </tzid>
+ </parameters>
+ <date-time>2009-09-08T16:00:00</date-time>
+ </recurrence-id>
+ <summary>
+ <text>Complex Task</text>
+ </summary>
+ <description>
+ <text>Some notes on this task.</text>
+ </description>
+ <priority>
+ <integer>1</integer>
+ </priority>
+ <percent-complete>
+ <integer>50</integer>
+ </percent-complete>
+ <location>
+ <text>Here</text>
+ </location>
+ <attendee>
+ <parameters>
+ <cn>
+ <text>Attendee1</text>
+ </cn>
+ <partstat>
+ <text>NEEDS-ACTION</text>
+ </partstat>
+ <role>
+ <text>REQ-PARTICIPANT</text>
+ </role>
+ <rsvp>
+ <boolean>true</boolean>
+ </rsvp>
+ </parameters>
+ <cal-address>mailto:%3Ca1%40example.com%3E</cal-address>
+ </attendee>
+ <attendee>
+ <parameters>
+ <cn>
+ <text>Attendee2</text>
+ </cn>
+ <partstat>
+ <text>TENTATIVE</text>
+ </partstat>
+ <role>
+ <text>REQ-PARTICIPANT</text>
+ </role>
+ <rsvp>
+ <boolean>true</boolean>
+ </rsvp>
+ </parameters>
+ <cal-address>mailto:%3Ca2%40example.com%3E</cal-address>
+ </attendee>
+ <attendee>
+ <parameters>
+ <cn>
+ <text>Attendee3</text>
+ </cn>
+ <partstat>
+ <text>ACCEPTED</text>
+ </partstat>
+ <role>
+ <text>OPT-PARTICIPANT</text>
+ </role>
+ </parameters>
+ <cal-address>mailto:%3Ca3%40example.com%3E</cal-address>
+ </attendee>
+ <attach>
+ <parameters>
+ <fmttype>
+ <text>image/png</text>
+ </fmttype>
+ <x-label>
+ <text>akonadi.png</text>
+ </x-label>
+ </parameters>
+ <uri>cid:2838853.9Y25si6h6e@kolab.resource.akonadi</uri>
+ </attach>
+ </properties>
+ <components>
+ <valarm>
+ <properties>
+ <action>
+ <text>DISPLAY</text>
+ </action>
+ <description>
+ <text/>
+ </description>
+ <trigger>
+ <parameters>
+ <related>
+ <text>END</text>
+ </related>
+ </parameters>
+ <duration>-PT900S</duration>
+ </trigger>
+ <duration>
+ <duration>PT5S</duration>
+ </duration>
+ <repeat>
+ <integer>0</integer>
+ </repeat>
+ </properties>
+ </valarm>
+ </components>
+ </vtodo>
+ </components>
+ </vcalendar>
+
+</icalendar>
+
+--nextPart1676922.i4WXLoZAWe
+Content-ID: <2838853.9Y25si6h6e@kolab.resource.akonadi>
+Content-Type: image/png; name="akonadi.png"
+Content-Transfer-Encoding: base64
+Content-Disposition: attachment; filename="akonadi.png"
+
+iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAAZiS0dEAP8A
+/wD/oL2nkwAAAAlwSFlzAAAbrwAAG68BXhqRHAAAAAd0SU1FB9gFEQkdFPibCIYAAAMrSURBVDjL
+pZNLaBx1AMZ/M/P/78zOzO7ObDbvNUnTxsUUm6YmaulNxN70UKEIRTyIBy8KHr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.i4WXLoZAWe--
diff --git a/test/synckolab/parser/kolab3/raw/contacttest-e79e08cc-0f02-11e2-9e3c-000476ed9009.eml b/test/synckolab/parser/kolab3/raw/contacttest-e79e08cc-0f02-11e2-9e3c-000476ed9009.eml
new file mode 100644
index 0000000..ec9de38
--- /dev/null
+++ b/test/synckolab/parser/kolab3/raw/contacttest-e79e08cc-0f02-11e2-9e3c-000476ed9009.eml
@@ -0,0 +1,100 @@
+MIME-Version: 1.0
+Content-Type: multipart/mixed;
+ boundary="=_07bdbe1f73f061d409fe68b2d5edc3b7"
+From: nikotest@demo.kolab.org
+To: nikotest@demo.kolab.org
+Date: Fri, 05 Oct 2012 17:39:52 +0200
+X-Kolab-Type: application/x-vnd.kolab.contact
+X-Kolab-Mime-Version: 3.0
+Subject: e79e08cc-0f02-11e2-9e3c-000476ed9009
+User-Agent: Roundcube Webmail/0.9-0.10.git954540a3.el6.kolab_3.0
+
+--=_07bdbe1f73f061d409fe68b2d5edc3b7
+Content-Transfer-Encoding: quoted-printable
+Content-Type: text/plain; charset=ISO-8859-1
+
+This is a Kolab Groupware object. To view this object you will need an emai=
+l client that understands the Kolab Groupware format. For a list of such em=
+ail clients please visit http://www.kolab.org/
+
+
+--=_07bdbe1f73f061d409fe68b2d5edc3b7
+Content-Transfer-Encoding: 8bit
+Content-Type: application/vcard+xml; charset=UTF-8;
+ name=kolab.xml
+Content-Disposition: attachment;
+ filename=kolab.xml
+
+<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
+<vcards xmlns="urn:ietf:params:xml:ns:vcard-4.0">
+
+ <vcard>
+ <uid>
+ <uri>urn:uuid:e79e08cc-0f02-11e2-9e3c-000476ed9009</uri>
+ </uid>
+ <x-kolab-version>
+ <text>3.0dev1</text>
+ </x-kolab-version>
+ <prodid>
+ <text>Libkolabxml-0.8.1</text>
+ </prodid>
+ <rev>
+ <timestamp>20121005T153952Z</timestamp>
+ </rev>
+ <kind>
+ <text>individual</text>
+ </kind>
+ <fn>
+ <text>firstname lastname</text>
+ </fn>
+ <n>
+ <surname>lastname</surname>
+ <given>firstname</given>
+ </n>
+ <note>
+ <text>multi line
+notes
+
+with empty</text>
+ </note>
+ <group name="Affiliation">
+ <org>
+ <text>company</text>
+ </org>
+ </group>
+ <adr>
+ <parameters>
+ <type>
+ <text>home</text>
+ </type>
+ </parameters>
+ <pobox/>
+ <ext/>
+ <street>homestreet</street>
+ <locality>homecity</locality>
+ <region>homestate</region>
+ <code>1234</code>
+ <country>homecountry</country>
+ </adr>
+ <bday>
+ <date>20121020</date>
+ </bday>
+ <gender>
+ <sex>M</sex>
+ </gender>
+ <tel>
+ <parameters>
+ <type>
+ <text>home</text>
+ </type>
+ </parameters>
+ <text>+43 homephone</text>
+ </tel>
+ <email>
+ <text>email1@test.com</text>
+ </email>
+ </vcard>
+
+</vcards>
+
+--=_07bdbe1f73f061d409fe68b2d5edc3b7--
diff --git a/test/synckolab/parser/kolab3/raw/kaltest-2D96EAF4BBB56DBB8A7D0D48122FD0DD-7F0077A606323E46.eml b/test/synckolab/parser/kolab3/raw/kaltest-2D96EAF4BBB56DBB8A7D0D48122FD0DD-7F0077A606323E46.eml
new file mode 100644
index 0000000..9c8d256
--- /dev/null
+++ b/test/synckolab/parser/kolab3/raw/kaltest-2D96EAF4BBB56DBB8A7D0D48122FD0DD-7F0077A606323E46.eml
@@ -0,0 +1,100 @@
+MIME-Version: 1.0
+Content-Type: multipart/mixed;
+ boundary="=_4219b74758af03607a2a947101c07d10"
+From: nikotest@demo.kolab.org
+To: nikotest@demo.kolab.org
+Date: Fri, 05 Oct 2012 17:40:45 +0200
+X-Kolab-Type: application/x-vnd.kolab.event
+X-Kolab-Mime-Version: 3.0
+Subject: 2D96EAF4BBB56DBB8A7D0D48122FD0DD-7F0077A606323E46
+User-Agent: Roundcube Webmail/0.9-0.10.git954540a3.el6.kolab_3.0
+
+--=_4219b74758af03607a2a947101c07d10
+Content-Transfer-Encoding: quoted-printable
+Content-Type: text/plain; charset=ISO-8859-1
+
+This is a Kolab Groupware object. To view this object you will need an emai=
+l client that understands the Kolab Groupware format. For a list of such em=
+ail clients please visit http://www.kolab.org/
+
+
+--=_4219b74758af03607a2a947101c07d10
+Content-Transfer-Encoding: 8bit
+Content-Type: application/calendar+xml; charset=UTF-8;
+ name=kolab.xml
+Content-Disposition: attachment;
+ filename=kolab.xml
+
+<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
+<icalendar xmlns="urn:ietf:params:xml:ns:icalendar-2.0">
+
+ <vcalendar>
+ <properties>
+ <prodid>
+ <text>Libkolabxml-0.8.1</text>
+ </prodid>
+ <version>
+ <text>2.0</text>
+ </version>
+ <x-kolab-version>
+ <text>3.0dev1</text>
+ </x-kolab-version>
+ </properties>
+ <components>
+ <vevent>
+ <properties>
+ <uid>
+ <text>2D96EAF4BBB56DBB8A7D0D48122FD0DD-7F0077A606323E46</text>
+ </uid>
+ <created>
+ <date-time>2012-10-05T15:40:45Z</date-time>
+ </created>
+ <dtstamp>
+ <date-time>2012-10-05T17:40:45Z</date-time>
+ </dtstamp>
+ <sequence>
+ <integer>1</integer>
+ </sequence>
+ <class>
+ <text>PUBLIC</text>
+ </class>
+ <dtstart>
+ <parameters>
+ <tzid>
+ <text>/kolab.org/Europe/Paris</text>
+ </tzid>
+ </parameters>
+ <date-time>2012-10-04T06:30:00</date-time>
+ </dtstart>
+ <dtend>
+ <parameters>
+ <tzid>
+ <text>/kolab.org/Europe/Paris</text>
+ </tzid>
+ </parameters>
+ <date-time>2012-10-04T07:00:00</date-time>
+ </dtend>
+ <summary>
+ <text>test</text>
+ </summary>
+ <description>
+ <text>testdescr</text>
+ </description>
+ <priority>
+ <integer>5</integer>
+ </priority>
+ <location>
+ <text>testloc</text>
+ </location>
+ <organizer>
+ <parameters/>
+ <cal-address>mailto:%3Cnikotest%40demo%2Ekolab%2Eorg%3E</cal-address>
+ </organizer>
+ </properties>
+ </vevent>
+ </components>
+ </vcalendar>
+
+</icalendar>
+
+--=_4219b74758af03607a2a947101c07d10--
diff --git a/test/synckolab/parser/kolab3/raw/simple.ics.mime b/test/synckolab/parser/kolab3/raw/simple.ics.mime
new file mode 100644
index 0000000..e582d2f
--- /dev/null
+++ b/test/synckolab/parser/kolab3/raw/simple.ics.mime
@@ -0,0 +1,86 @@
+Date: Mon, 23 Apr 2012 12:33:34 +0200
+X-Kolab-Type: application/x-vnd.kolab.event
+X-Kolab-Mime-Version: 3.0
+User-Agent: Libkolab-0.1.0
+Content-Type: multipart/mixed; boundary="nextPart1440420.ZGVZUGuhry"
+Subject: KOrganizer-1353608432.168
+MIME-Version: 1.0
+
+
+--nextPart1440420.ZGVZUGuhry
+Content-Type: text/plain; charset="us-ascii"
+Content-Transfer-Encoding: 7Bit
+
+This is a Kolab Groupware object.
+To view this object you will need an email client that can understand the Kolab Groupware format.
+For a list of such email clients please visit
+http://www.kolab.org/get-kolab
+
+--nextPart1440420.ZGVZUGuhry
+Content-Type: application/calendar+xml; name="kolab.xml"
+Content-Transfer-Encoding: quoted-printable
+Content-Disposition: attachment; filename="kolab.xml"
+
+<?xml version=3D"1.0" encoding=3D"UTF-8" standalone=3D"no" ?>
+<icalendar xmlns=3D"urn:ietf:params:xml:ns:icalendar-2.0">
+
+ <vcalendar>
+ <properties>
+ <prodid>
+ <text>Libkolab-0.1.0 Libkolabxml-0.3.0</text>
+ </prodid>
+ <version>
+ <text>2.0</text>
+ </version>
+ <x-kolab-version>
+ <text>3.0dev1</text>
+ </x-kolab-version>
+ </properties>
+ <components>
+ <vevent>
+ <properties>
+ <uid>
+ <text>KOrganizer-1353608432.168</text>
+ </uid>
+ <created>
+ <date-time>2009-09-01T11:36:44Z</date-time>
+ </created>
+ <dtstamp>
+ <date-time>2012-05-05T05:05:05Z</date-time>
+ </dtstamp>
+ <sequence>
+ <integer>0</integer>
+ </sequence>
+ <class>
+ <text>PUBLIC</text>
+ </class>
+ <dtstart>
+ <parameters>
+ <tzid>
+ <text>/kolab.org/Europe/Berlin</text>
+ </tzid>
+ </parameters>
+ <date-time>2009-09-02T08:00:00</date-time>
+ </dtstart>
+ <dtend>
+ <parameters>
+ <tzid>
+ <text>/kolab.org/Europe/Berlin</text>
+ </tzid>
+ </parameters>
+ <date-time>2009-09-02T09:00:00</date-time>
+ </dtend>
+ <summary>
+ <text>Simple Event</text>
+ </summary>
+ <location>
+ <text>Here</text>
+ </location>
+ </properties>
+ </vevent>
+ </components>
+ </vcalendar>
+
+</icalendar>
+
+--nextPart1440420.ZGVZUGuhry-- \ No newline at end of file
diff --git a/test/synckolab/parser/kolab3/raw/simple.task.ics.mime b/test/synckolab/parser/kolab3/raw/simple.task.ics.mime
new file mode 100644
index 0000000..8849b77
--- /dev/null
+++ b/test/synckolab/parser/kolab3/raw/simple.task.ics.mime
@@ -0,0 +1,70 @@
+Date: Fri, 27 Apr 2012 16:56:44 +0200
+X-Kolab-Type: application/x-vnd.kolab.task
+X-Kolab-Mime-Version: 3.0
+User-Agent: Libkolab-0.2.0
+Content-Type: multipart/mixed; boundary="nextPart7341281.t3AojKazdB"
+Subject: KOrganizer-2105012348.490
+MIME-Version: 1.0
+
+
+--nextPart7341281.t3AojKazdB
+Content-Type: text/plain; charset="us-ascii"
+Content-Transfer-Encoding: 7Bit
+
+This is a Kolab Groupware object.
+To view this object you will need an email client that can understand the Kolab Groupware format.
+For a list of such email clients please visit
+http://www.kolab.org/get-kolab
+
+--nextPart7341281.t3AojKazdB
+Content-Type: application/calendar+xml; name="kolab.xml"
+Content-Transfer-Encoding: quoted-printable
+Content-Disposition: attachment; filename="kolab.xml"
+
+<?xml version=3D"1.0" encoding=3D"UTF-8" standalone=3D"no" ?>
+<icalendar xmlns=3D"urn:ietf:params:xml:ns:icalendar-2.0">
+
+ <vcalendar>
+ <properties>
+ <prodid>
+ <text>Libkolab-0.2.0 Libkolabxml-0.4.0</text>
+ </prodid>
+ <version>
+ <text>2.0</text>
+ </version>
+ <x-kolab-version>
+ <text>3.0dev1</text>
+ </x-kolab-version>
+ </properties>
+ <components>
+ <vtodo>
+ <properties>
+ <uid>
+ <text>KOrganizer-2105012348.490</text>
+ </uid>
+ <created>
+ <date-time>2009-09-01T13:17:03Z</date-time>
+ </created>
+ <dtstamp>
+ <date-time>2012-05-05T05:05:05Z</date-time>
+ </dtstamp>
+ <sequence>
+ <integer>0</integer>
+ </sequence>
+ <class>
+ <text>PUBLIC</text>
+ </class>
+ <summary>
+ <text>Simple Task</text>
+ </summary>
+ <priority>
+ <integer>7</integer>
+ </priority>
+ </properties>
+ </vtodo>
+ </components>
+ </vcalendar>
+
+</icalendar>
+
+--nextPart7341281.t3AojKazdB--
diff --git a/test/synckolab/parser/kolab3/raw/utf8base64.ics.mime b/test/synckolab/parser/kolab3/raw/utf8base64.ics.mime
new file mode 100644
index 0000000..1067f33
--- /dev/null
+++ b/test/synckolab/parser/kolab3/raw/utf8base64.ics.mime
@@ -0,0 +1,54 @@
+Date: Fri, 17 Aug 2012 18:00:15 +0000
+X-Kolab-Type: application/x-vnd.kolab.event
+X-Kolab-Mime-Version: 3.0
+User-Agent: Libkolab-0.3.1
+Content-Type: multipart/mixed; boundary="nextPart1896568.xMY9UUPWVa"
+Subject: KOrganizer-1353608432.168
+MIME-Version: 1.0
+
+
+--nextPart1896568.xMY9UUPWVa
+Content-Type: text/plain; charset="us-ascii"
+Content-Transfer-Encoding: 7Bit
+
+This is a Kolab Groupware object.
+To view this object you will need an email client that can understand the Kolab Groupware format.
+For a list of such email clients please visit
+http://www.kolab.org/get-kolab
+
+--nextPart1896568.xMY9UUPWVa
+Content-Type: application/calendar+xml; name="kolab.xml"
+Content-Transfer-Encoding: base64
+Content-Disposition: attachment; filename="kolab.xml"
+
+PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiIHN0YW5kYWxvbmU9Im5vIiA/Pgo8
+aWNhbGVuZGFyIHhtbG5zPSJ1cm46aWV0ZjpwYXJhbXM6eG1sOm5zOmljYWxlbmRhci0yLjAiPgoK
+ICA8dmNhbGVuZGFyPgogICAgPHByb3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yb3BlL0Jlcmxp
+bjwvdGV4dD4KICAgICAgICAgICAgICA8L3R6aWQ+CiAgICAgICAgICAgIDwvcGFyYW1ldGVycz4K
+ICAgICAgICAgICAgPGRhdGUtdGltZT4yMDA5LTA5LTAyVDA4OjAwOjAwPC9kYXRlLXRpbWU+CiAg
+ICAgICAgICA8L2R0c3RhcnQ+CiAgICAgICAgICA8ZHRlbmQ+CiAgICAgICAgICAgIDxwYXJhbWV0
+ZXJzPgogICAgICAgICAgICAgIDx0emlkPgogICAgICAgICAgICAgICAgPHRleHQ+L2tvbGFiLm9y
+Zy9FdXJvcGUvQmVybGluPC90ZXh0PgogICAgICAgICAgICAgIDwvdHppZD4KICAgICAgICAgICAg
+PC9wYXJhbWV0ZXJzPgogICAgICAgICAgICA8ZGF0ZS10aW1lPjIwMDktMDktMDJUMDk6MDA6MDA8
+L2RhdGUtdGltZT4KICAgICAgICAgIDwvZHRlbmQ+CiAgICAgICAgICA8c3VtbWFyeT4KICAgICAg
+ICAgICAgPHRleHQ+w6TDtsO8JUAkwqPDqcKkwrzCssKw4oKsxaDvv73ZgNij2KjZgDwvdGV4dD4K
+ICAgICAgICAgIDwvc3VtbWFyeT4KICAgICAgICAgIDxsb2NhdGlvbj4KICAgICAgICAgICAgPHRl
+eHQ+w6TDtsO8JUAkwqPDqcKkwrzCssKw4oKsxaDvv73ZgNij2KjZgDwvdGV4dD4KICAgICAgICAg
+IDwvbG9jYXRpb24+CiAgICAgICAgPC9wcm9wZXJ0aWVzPgogICAgICA8L3ZldmVudD4KICAgIDwv
+Y29tcG9uZW50cz4KICA8L3ZjYWxlbmRhcj4KCjwvaWNhbGVuZGFyPgo=
+
+--nextPart1896568.xMY9UUPWVa--
diff --git a/test/synckolab/parser/kolab3/raw/utf8quotedPrintable.ics.mime b/test/synckolab/parser/kolab3/raw/utf8quotedPrintable.ics.mime
new file mode 100644
index 0000000..92552e7
--- /dev/null
+++ b/test/synckolab/parser/kolab3/raw/utf8quotedPrintable.ics.mime
@@ -0,0 +1,88 @@
+Date: Fri, 17 Aug 2012 17:47:13 +0000
+X-Kolab-Type: application/x-vnd.kolab.event
+X-Kolab-Mime-Version: 3.0
+User-Agent: Libkolab-0.3.1
+Content-Type: multipart/mixed; boundary="nextPart1387272.PG4QbOfaIz"
+Subject: KOrganizer-1353608432.168
+MIME-Version: 1.0
+
+
+--nextPart1387272.PG4QbOfaIz
+Content-Type: text/plain; charset="us-ascii"
+Content-Transfer-Encoding: 7Bit
+
+This is a Kolab Groupware object.
+To view this object you will need an email client that can understand the Kolab Groupware format.
+For a list of such email clients please visit
+http://www.kolab.org/get-kolab
+
+--nextPart1387272.PG4QbOfaIz
+Content-Type: application/calendar+xml; name="kolab.xml"
+Content-Transfer-Encoding: quoted-printable
+Content-Disposition: attachment; filename="kolab.xml"
+
+<?xml version=3D"1.0" encoding=3D"UTF-8" standalone=3D"no" ?>
+<icalendar xmlns=3D"urn:ietf:params:xml:ns:icalendar-2.0">
+
+ <vcalendar>
+ <properties>
+ <prodid>
+ <text>Libkolab-0.3.1 Libkolabxml-0.5</text>
+ </prodid>
+ <version>
+ <text>2.0</text>
+ </version>
+ <x-kolab-version>
+ <text>3.0dev1</text>
+ </x-kolab-version>
+ </properties>
+ <components>
+ <vevent>
+ <properties>
+ <uid>
+ <text>KOrganizer-1353608432.168</text>
+ </uid>
+ <created>
+ <date-time>2009-09-01T11:36:44Z</date-time>
+ </created>
+ <dtstamp>
+ <date-time>2009-09-01T11:36:44Z</date-time>
+ </dtstamp>
+ <sequence>
+ <integer>0</integer>
+ </sequence>
+ <class>
+ <text>PUBLIC</text>
+ </class>
+ <dtstart>
+ <parameters>
+ <tzid>
+ <text>/kolab.org/Europe/Berlin</text>
+ </tzid>
+ </parameters>
+ <date-time>2009-09-02T08:00:00</date-time>
+ </dtstart>
+ <dtend>
+ <parameters>
+ <tzid>
+ <text>/kolab.org/Europe/Berlin</text>
+ </tzid>
+ </parameters>
+ <date-time>2009-09-02T09:00:00</date-time>
+ </dtend>
+ <summary>
+ <text>=C3=A4=C3=B6=C3=BC%@$=C2=A3=C3=A9=C2=A4=C2=BC=C2=B2=C2=
+=B0=E2=82=AC=C5=A0=EF=BF=BD=D9=80=D8=A3=D8=A8=D9=80</text>
+ </summary>
+ <location>
+ <text>=C3=A4=C3=B6=C3=BC%@$=C2=A3=C3=A9=C2=A4=C2=BC=C2=B2=C2=
+=B0=E2=82=AC=C5=A0=EF=BF=BD=D9=80=D8=A3=D8=A8=D9=80</text>
+ </location>
+ </properties>
+ </vevent>
+ </components>
+ </vcalendar>
+
+</icalendar>
+
+--nextPart1387272.PG4QbOfaIz--