summaryrefslogtreecommitdiff
path: root/test/synckolab/parser/kolab3
diff options
context:
space:
mode:
authorniko <niko>2012-10-27 00:43:25 (GMT)
committerniko <niko>2012-10-27 00:43:25 (GMT)
commit23f86ba282449381f8ed5dc82b50673a02c6b93f (patch)
treeb6ebeb34684c53bc09620727f0443c18be6be0f4 /test/synckolab/parser/kolab3
parent3ce6a3cf783d624c84e0a05a6a03310ad43c6e9a (diff)
downloadsynckolab-23f86ba282449381f8ed5dc82b50673a02c6b93f.tar.gz
rewrite parsing
Diffstat (limited to 'test/synckolab/parser/kolab3')
-rw-r--r--test/synckolab/parser/kolab3/calendarTest.js4
-rw-r--r--test/synckolab/parser/kolab3/contactTest.js13
-rw-r--r--test/synckolab/parser/kolab3/json/contact.complex.mime.json6
-rw-r--r--test/synckolab/parser/kolab3/json/contact.simple.mime.json4
-rw-r--r--test/synckolab/parser/kolab3/json/contact.test.mime.json4
-rw-r--r--test/synckolab/parser/kolab3/json/contact.test2.mime.json4
-rw-r--r--test/synckolab/parser/kolab3/json/contact.test3.mime.json1
-rw-r--r--test/synckolab/parser/kolab3/raw/contact.complex.mime2
-rw-r--r--test/synckolab/parser/kolab3/raw/contact.test3.mime50
-rw-r--r--test/synckolab/parser/kolab3/xml/contact.complex.mime.xml7
-rw-r--r--test/synckolab/parser/kolab3/xml/contact.simple.mime.xml1
-rw-r--r--test/synckolab/parser/kolab3/xml/contact.test.mime.xml1
-rw-r--r--test/synckolab/parser/kolab3/xml/contact.test2.mime.xml1
-rw-r--r--test/synckolab/parser/kolab3/xml/contact.test3.mime.xml17
14 files changed, 95 insertions, 20 deletions
diff --git a/test/synckolab/parser/kolab3/calendarTest.js b/test/synckolab/parser/kolab3/calendarTest.js
index e3c912b..a5f64be 100644
--- a/test/synckolab/parser/kolab3/calendarTest.js
+++ b/test/synckolab/parser/kolab3/calendarTest.js
@@ -21,7 +21,7 @@ test("kolab3 synckolab.addressbookTools.parseMessageContent", function(){
print("INFO: KOLAB 3 TESTING - EVENT: " + src +"\n")
content = readFile("test/synckolab/parser/kolab3/raw/"+src);
- content = synckolab.tools.stripMailHeader(content);
+ content = synckolab.tools.parseMail(content);
entry = synckolab.calendarTools.message2json(content, false);
content = readFile("test/synckolab/parser/kolab3/json/"+src+".json");
jsonEntry = JSON.parse(content);
@@ -42,7 +42,7 @@ test("kolab3 synckolab.addressbookTools.parseMessageContent", function(){
var src = testFiles[i];
content = readFile("test/synckolab/parser/kolab3/raw/"+src);
- content = synckolab.tools.stripMailHeader(content);
+ content = synckolab.tools.parseMail(content);
print(content);
print("==== STARTING PARSE")
entry = synckolab.calendarTools.message2json(content, false);
diff --git a/test/synckolab/parser/kolab3/contactTest.js b/test/synckolab/parser/kolab3/contactTest.js
index 3a66a08..b24dc69 100644
--- a/test/synckolab/parser/kolab3/contactTest.js
+++ b/test/synckolab/parser/kolab3/contactTest.js
@@ -12,7 +12,7 @@ load("test/lib/testOverride.js");
test("kolab3 synckolab.addressbookTools.parseMessageContent", function(){
equal(null, synckolab.addressbookTools.parseMessageContent(null), "parsing a null message");
- var testFiles = ["contact.simple.mime","contact.complex.mime","contact.test.mime","contact.test2.mime", "list.test1.eml"];
+ var testFiles = ["contact.test3.mime", "contact.simple.mime","contact.complex.mime","contact.test.mime","contact.test2.mime", "list.test1.eml"];
var content, entry, jsonEntry;
@@ -20,7 +20,7 @@ test("kolab3 synckolab.addressbookTools.parseMessageContent", function(){
var src = testFiles[i];
print("INFO: KOLAB 3 TESTING - CONTACT: " + src +"\n")
content = readFile("test/synckolab/parser/kolab3/raw/"+src);
- content = synckolab.tools.stripMailHeader(content);
+ content = synckolab.tools.parseMail(content);
entry = synckolab.addressbookTools.parseMessageContent(content);
content = readFile("test/synckolab/parser/kolab3/json/"+src+".json");
jsonEntry = JSON.parse(content);
@@ -32,6 +32,9 @@ test("kolab3 synckolab.addressbookTools.parseMessageContent", function(){
} else {
content = synckolab.addressbookTools.card2Kolab3(entry);
}
+ if(content.content) {
+ content = content.content;
+ }
xmlcontent = readFile("test/synckolab/parser/kolab3/xml/"+src + ".xml");
if (xmlcontent.replace(/[\n\r\t ]/g, "").length !== content.replace(/[\n\r\t ]/g, "").length) {
equal(xmlcontent.replace(/[\n\r\t ]/g, ""), content.replace(/[\n\r\t ]/g, ""), src);
@@ -47,7 +50,7 @@ for(var i = 0; i < testFiles.length; i++) {
var src = testFiles[i];
print("KOLAB 3 TESTING: " + src +"\n============")
content = readFile("test/synckolab/parser/kolab3/raw/"+src);
- content = synckolab.tools.stripMailHeader(content);
+ content = synckolab.tools.parseMail(content);
entry = synckolab.addressbookTools.parseMessageContent(content);
if(entry.isMailList) {
print(entry.toSource());
@@ -68,7 +71,7 @@ for(var i = 0; i < testFiles.length; i++) {
print("DIFF FOUND:"+ xmlcontent.replace(/[\n\r\t ]/g, "").length + " vs. "+ content.replace(/[\n\r\t ]/g, "").length +"\n" + diff);
}
}
-*/
+
/*
var testFiles = ["list.test1.eml"];
@@ -79,7 +82,7 @@ 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);
+ content = synckolab.tools.parseMail(content);
print(content);
print("==== STARTING PARSE")
entry = synckolab.addressbookTools.parseMessageContent(content);
diff --git a/test/synckolab/parser/kolab3/json/contact.complex.mime.json b/test/synckolab/parser/kolab3/json/contact.complex.mime.json
index c2cb6d0..eb613e6 100644
--- a/test/synckolab/parser/kolab3/json/contact.complex.mime.json
+++ b/test/synckolab/parser/kolab3/json/contact.complex.mime.json
@@ -5,14 +5,14 @@
"ts": 1349565039427,
"UUID": "urn:uuid:Huu5X7hfYy",
"DisplayName": "Displayname",
- "FirstName": "Lastname",
- "LastName": "Firstname",
+ "FirstName": "Firstname",
+ "LastName": "Lastname",
"Notes": "Notes",
"JobTitle": "Title",
"Profession": "Profession",
"PhotoName": "photo.png",
"PhotoType": "inline",
- "PhotoData": "iVBORw0KGgoAAAANSUhEUgAAAGQAAABkCAYAAABw4pVUAAAAB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H4jbLg1WkUzhAwJIUNCyJAQMiSEDL/LumQXvENDhaFHKB/sG4QbyZaiJfgTblLDXYuZWZzHnc56irum9SzOkw6/RtOaOE9xnjTxWJmwff/XmiFkSAgZEkKGhJAhIWT4XVYQuOtMS7Vl+J6ON3+/gedv7NvAA5X8G0uL+HUj5j1eCfu7TfLNjjmlzdlz19XEz3VuBc0QMiSEDAkhQ0LIkBAy/C7rQfOxd2jl6toCygufFJ6jPGlEPSiv5+p+/b1OXnByr/varAHyuinv6QLn/CByG9KW0QwhQ0LIkBAyJIQMCSFDQsjY2ka5+8nvKF6ZXv4Y5YWBnl9R3pfthOebmS1nl/C9dToXOO1wrj/nlbAocVYLvXZ4FcdBs32P2WiGkCEhZEgIGRJChoSQ0d6ncG/bfyheSatHUd71c/dDb6gDuQ+mUL6Y/gNX8tIUt0Z9/7qv7bVKXME74jIbeLXQ+SU6zKjLemeREDIkhAwJIUNCyNieN8p14NWhutUuepdEPzVeofxQbugWyivVRa/78r8A8Zf9CPOBzA0U70lC+PcK0qBtX5nQDCFDQsiQEDIkhAwJIWP3fYPqevg5ig8ePPALynu7e72tdfbnk3m8je54eArF+8v7n6G8mOnza7xwaugbVLsDCSFDQsiQEDIkhAwJIWP3tb0eNw2+MTnoyl7zLmlOx985h/DvwV6Nnk1qfNtaDc0QMiSEDAkhQ0LIkBAhhBBCCPEe8D+b5dDLeP4TXAAAAABJRU5ErkJggg==",
"WebPage1": "www.homepage.org",
"WebPage2": "www.blog.test",
"HomeAddress": "Home Street",
diff --git a/test/synckolab/parser/kolab3/json/contact.simple.mime.json b/test/synckolab/parser/kolab3/json/contact.simple.mime.json
index 6e779b9..d330f4e 100644
--- a/test/synckolab/parser/kolab3/json/contact.simple.mime.json
+++ b/test/synckolab/parser/kolab3/json/contact.simple.mime.json
@@ -5,8 +5,8 @@
"ts": 1349536624864,
"UUID": "urn:uuid:4xuyC0cyjV",
"DisplayName": "Volker Krause",
- "FirstName": "Krause",
- "LastName": "Volker",
+ "FirstName": "Volker",
+ "LastName": "Krause",
"PrimaryEmail": "vkrause@kde.org",
"sha1": "b93a56ffad8ad756d72ca9aae70f49e4bd85ecb8"
} \ No newline at end of file
diff --git a/test/synckolab/parser/kolab3/json/contact.test.mime.json b/test/synckolab/parser/kolab3/json/contact.test.mime.json
index bff573d..d8aa331 100644
--- a/test/synckolab/parser/kolab3/json/contact.test.mime.json
+++ b/test/synckolab/parser/kolab3/json/contact.test.mime.json
@@ -5,8 +5,8 @@
"ts": 1349900866998,
"UUID": "urn:uuid:e79e08cc-0f02-11e2-9e3c-000476ed9009",
"DisplayName": "firstname lastname",
- "FirstName": "lastname",
- "LastName": "firstname",
+ "FirstName": "firstname",
+ "LastName": "lastname",
"Notes": "multi line\nnotes\n\nwith empty",
"HomeAddress": "homestreet",
"HomeAddress2": "",
diff --git a/test/synckolab/parser/kolab3/json/contact.test2.mime.json b/test/synckolab/parser/kolab3/json/contact.test2.mime.json
index 7c35a9a..6c08d2f 100644
--- a/test/synckolab/parser/kolab3/json/contact.test2.mime.json
+++ b/test/synckolab/parser/kolab3/json/contact.test2.mime.json
@@ -5,8 +5,8 @@
"ts": 1349900714929,
"UUID": "urn: uuid:ebf6fdc2-1149-11e2-841b-000476ed9009",
"DisplayName": "Hans Wurst",
- "FirstName": "Wurst",
- "LastName": "Hans",
+ "FirstName": "Hans",
+ "LastName": "Wurst",
"HomePhone": "+49123456789",
"PrimaryEmail": "hans@wurst.de",
"sha1": "c4ea78596ac0cf988a5d6dac68f1510b9ef66b13"
diff --git a/test/synckolab/parser/kolab3/json/contact.test3.mime.json b/test/synckolab/parser/kolab3/json/contact.test3.mime.json
new file mode 100644
index 0000000..d16e37c
--- /dev/null
+++ b/test/synckolab/parser/kolab3/json/contact.test3.mime.json
@@ -0,0 +1 @@
+{"synckolab":"2.9.0","type":"contact","isMailList":false,"ts":1351269299411,"UUID":"urn:uuid:pas-id-A4E937D838A897AD","DisplayName":"cont2#öüä&$","PrimaryEmail":"weird@email.com","PreferMailFormat":0,"AllowRemoteContent":true,"sha1":"f1b30ff3264e645934db12e2894016a83916af8b"} \ No newline at end of file
diff --git a/test/synckolab/parser/kolab3/raw/contact.complex.mime b/test/synckolab/parser/kolab3/raw/contact.complex.mime
index 4a3d52a..54ade78 100644
--- a/test/synckolab/parser/kolab3/raw/contact.complex.mime
+++ b/test/synckolab/parser/kolab3/raw/contact.complex.mime
@@ -84,7 +84,7 @@ CBkSQoaEkJE2M++8vn+OvwNMTw9fhw3ZPdyh5e1lJVVxGp3XClK/wrwwFv6dUOTrpBGcRDO=
EDAkhQ0LIkBAyJISMpHt7z5QwF+Or4LrwDW3NMt5/2rvv3ANiZmFXGn4gh6bxpbqZEXxNRp=
CJhr0a7aIZQoaEkCEhZEgIGRJChoSQQbvsrZb/gA987Jb6fkL5fiX6FOV3y7kvvBoDqTQ8R=
TezY2+hvK8/WEJ52Ki3d1tyApohZEgIGRJChoSQISFk0K6yPto4gGf/l5cP/N/RaB/n2QaD=
-vyT28dIcPvQ2sNnjl9C9vecaCSFDQsiQEDIkhIx/AF4jzh2wCYImAAAAAElFTkSuQmCC</u=
+vyT28dIcPvQ2sNnjl9C9vecaCSFDQsiQEDIkhIx/AF4jzh2wCYImAAAAAElFTkSuQmCC==</u=
ri>
</logo>
<related>
diff --git a/test/synckolab/parser/kolab3/raw/contact.test3.mime b/test/synckolab/parser/kolab3/raw/contact.test3.mime
new file mode 100644
index 0000000..849a35a
--- /dev/null
+++ b/test/synckolab/parser/kolab3/raw/contact.test3.mime
@@ -0,0 +1,50 @@
+From: niko.berger@corinis.com
+Reply-To:
+Bcc:
+To: synckolab@no.tld
+Subject: urn:uuid:pas-id-A4E937D838A897AD
+Date: Fri, 26 Oct 2012 17:25:49 +0200
+Content-Type: Multipart/Mixed;boundary="Boundary-00=D2A398834E826D6C"
+User-Agent: SyncKolab 2.9.0
+X-Kolab-Type: application/vcard+xml
+
+--Boundary-00=D2A398834E826D6C
+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://kolab.org/content/kolab-clients
+---
+Name: cont2#&$
+E-Mail:weird@email.com
+---
+
+Notice:
+The information above is only valid, if no other client than synckolab updated this message. (ie. a client that updates the attachment but not the message)
+
+--Boundary-00=D2A398834E826D6C
+Content-Type: application/vcard+xml;
+ name="kolab.xml"
+Content-Transfer-Encoding: base64
+Content-Disposition: attachment;
+ filename="kolab.xml"
+
+PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiIHN0YW5kYWxvbmU9Im5vIiA/
+Pgo8dmNhcmRzIHhtbG5zPSJ1cm46aWV0ZjpwYXJhbXM6eG1sOm5zOnZjYXJkLTQuMCI+Cjx2
+Y2FyZD4KIDx1aWQ+PHVyaT51cm46dXVpZDpwYXMtaWQtQTRFOTM3RDgzOEE4OTdBRDwvdXJp
+PjwvdWlkPgogPHgta29sYWItdmVyc2lvbj48dGV4dD4zLjBkZXYxPC90ZXh0PjwveC1rb2xh
+Yi12ZXJzaW9uPgogPHByb2RpZD48dGV4dD5TeW5jS29sYWIgMi45LjAsIEtvbGFiIHJlc291
+cmNlPC90ZXh0PjwvcHJvZGlkPgogPHJldj48dGltZXN0YW1wPjE5NzAwMTAxVDAwMDAwMFpa
+PC90aW1lc3RhbXA+PC9yZXY+CiA8a2luZD48dGV4dD5pbmRpdmlkdWFsPC90ZXh0Pjwva2lu
+ZD4KICA8Zm4+PHRleHQ+Y29udDIjw7bDvMOkJmFtcDskPC90ZXh0PjwvZm4+CiA8ZW1haWw+
+CiAgPHBhcmFtZXRlcnM+PHByZWY+PGludGVnZXI+MTwvaW50ZWdlcj48L3ByZWY+PC9wYXJh
+bWV0ZXJzPgogIDx0ZXh0PndlaXJkQGVtYWlsLmNvbTwvdGV4dD4KIDwvZW1haWw+Cjx4LWN1
+c3RvbT48aWRlbnRpZmllcj5YLVByZWZlck1haWxGb3JtYXQ8L2lkZW50aWZpZXI+PHZhbHVl
+PnVua25vd248L3ZhbHVlPjwveC1jdXN0b20+CiA8eC1jdXN0b20+PGlkZW50aWZpZXI+WC1B
+bGxvd1JlbW90ZUNvbnRlbnQ8L2lkZW50aWZpZXI+PHZhbHVlPnRydWU8L3ZhbHVlPjwveC1j
+dXN0b20+CjwvdmNhcmQ+CjwvdmNhcmRzPgo=
+
+--Boundary-00=D2A398834E826D6C--
diff --git a/test/synckolab/parser/kolab3/xml/contact.complex.mime.xml b/test/synckolab/parser/kolab3/xml/contact.complex.mime.xml
index 1892809..193c291 100644
--- a/test/synckolab/parser/kolab3/xml/contact.complex.mime.xml
+++ b/test/synckolab/parser/kolab3/xml/contact.complex.mime.xml
@@ -8,8 +8,8 @@
<kind><text>individual</text></kind>
<fn><text>Displayname</text></fn>
<n>
- <surname>Firstname</surname>
- <given>Lastname</given>
+ <surname>Lastname</surname>
+ <given>Firstname</given>
</n>
<note>
<text>Notes</text>
@@ -70,7 +70,7 @@ IUt0Z9/7qv7bVKXME74jIbeLXQ+SU6zKjLemeREDIkhAwJIUNCyNieN8p14NWhutUuepdEP
zVeofxQbugWyivVRa/78r8A8Zf9CPOBzA0U70lC+PcK0qBtX5nQDCFDQsiQEDIkhAwJIWP3
fYPqevg5ig8ePPALynu7e72tdfbnk3m8je54eArF+8v7n6G8mOnza7xwaugbVLsDCSFDQsi
QEDIkhAwJIWP3tb0eNw2+MTnoyl7zLmlOx985h/DvwV6Nnk1qfNtaDc0QMiSEDAkhQ0LIkB
-AhhBBCCPEe8D+b5dDLeP4TXAAAAABJRU5ErkJggg</uri>
+AhhBBCCPEe8D+b5dDLeP4TXAAAAABJRU5ErkJggg==</uri>
</photo>
<tel>
<parameters><type><text>home</text></type></parameters>
@@ -99,6 +99,7 @@ AhhBBCCPEe8D+b5dDLeP4TXAAAAABJRU5ErkJggg</uri>
<text>second@email.org</text>
</email>
<x-custom><identifier>Profession</identifier><value>Profession</value></x-custom>
+ <x-custom><identifier>X-PreferMailFormat</identifier><value>unknown</value></x-custom>
<x-custom><identifier>X-AllowRemoteContent</identifier><value>true</value></x-custom>
</vcard>
</vcards> \ No newline at end of file
diff --git a/test/synckolab/parser/kolab3/xml/contact.simple.mime.xml b/test/synckolab/parser/kolab3/xml/contact.simple.mime.xml
index 36fe656..b507b69 100644
--- a/test/synckolab/parser/kolab3/xml/contact.simple.mime.xml
+++ b/test/synckolab/parser/kolab3/xml/contact.simple.mime.xml
@@ -17,6 +17,7 @@
<parameters><pref><integer>1</integer></pref></parameters>
<text>vkrause@kde.org</text>
</email>
+ <x-custom><identifier>X-PreferMailFormat</identifier><value>unknown</value></x-custom>
<x-custom><identifier>X-AllowRemoteContent</identifier><value>false</value></x-custom>
</vcard>
</vcards> \ No newline at end of file
diff --git a/test/synckolab/parser/kolab3/xml/contact.test.mime.xml b/test/synckolab/parser/kolab3/xml/contact.test.mime.xml
index 19e7b22..77eba92 100644
--- a/test/synckolab/parser/kolab3/xml/contact.test.mime.xml
+++ b/test/synckolab/parser/kolab3/xml/contact.test.mime.xml
@@ -36,6 +36,7 @@ with empty</text>
<code>1234</code>
<country>homecountry</country>
</adr>
+ <x-custom><identifier>X-PreferMailFormat</identifier><value>unknown</value></x-custom>
<x-custom><identifier>X-AllowRemoteContent</identifier><value>false</value></x-custom>
</vcard>
</vcards> \ No newline at end of file
diff --git a/test/synckolab/parser/kolab3/xml/contact.test2.mime.xml b/test/synckolab/parser/kolab3/xml/contact.test2.mime.xml
index 5a92b9b..8ecf7d8 100644
--- a/test/synckolab/parser/kolab3/xml/contact.test2.mime.xml
+++ b/test/synckolab/parser/kolab3/xml/contact.test2.mime.xml
@@ -21,6 +21,7 @@
<parameters><pref><integer>1</integer></pref></parameters>
<text>hans@wurst.de</text>
</email>
+ <x-custom><identifier>X-PreferMailFormat</identifier><value>unknown</value></x-custom>
<x-custom><identifier>X-AllowRemoteContent</identifier><value>false</value></x-custom>
</vcard>
</vcards> \ No newline at end of file
diff --git a/test/synckolab/parser/kolab3/xml/contact.test3.mime.xml b/test/synckolab/parser/kolab3/xml/contact.test3.mime.xml
new file mode 100644
index 0000000..52d2ebb
--- /dev/null
+++ b/test/synckolab/parser/kolab3/xml/contact.test3.mime.xml
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
+<vcards xmlns="urn:ietf:params:xml:ns:vcard-4.0">
+<vcard>
+ <uid><uri>urn:uuid:pas-id-A4E937D838A897AD</uri></uid>
+ <x-kolab-version><text>3.0dev1</text></x-kolab-version>
+ <prodid><text>SyncKolab 2.9.0, Kolab resource</text></prodid>
+ <rev><timestamp>19700101T000000ZZ</timestamp></rev>
+ <kind><text>individual</text></kind>
+ <fn><text>cont2#öüä&amp;$</text></fn>
+ <email>
+ <parameters><pref><integer>1</integer></pref></parameters>
+ <text>weird@email.com</text>
+ </email>
+ <x-custom><identifier>X-PreferMailFormat</identifier><value>unknown</value></x-custom>
+ <x-custom><identifier>X-AllowRemoteContent</identifier><value>true</value></x-custom>
+</vcard>
+</vcards>