summaryrefslogtreecommitdiff
path: root/test/synckolab/parser
diff options
context:
space:
mode:
authorniko <niko>2012-10-26 12:10:43 (GMT)
committerniko <niko>2012-10-26 12:10:43 (GMT)
commit238dc34ac96a1a1268e2d5e27e07009157920cd2 (patch)
tree093a445feb7e370a0899c0ecd14b79090576e273 /test/synckolab/parser
parent15b7152f1e238951bb958dca427af4470261d9ee (diff)
downloadsynckolab-238dc34ac96a1a1268e2d5e27e07009157920cd2.tar.gz
fix utf-8 handling and cleaned contact parsing
Diffstat (limited to 'test/synckolab/parser')
-rw-r--r--test/synckolab/parser/kolab2/contactTest.js6
-rw-r--r--test/synckolab/parser/kolab2/json/list.test.json12
-rw-r--r--test/synckolab/parser/kolab2/json/testcontact.json16
-rw-r--r--test/synckolab/parser/kolab2/raw/contactFullTest.eml (renamed from test/synckolab/parser/kolab2/raw/contactFullTest.xml)33
-rw-r--r--test/synckolab/parser/kolab2/raw/contactMinimalTest.eml43
-rw-r--r--test/synckolab/parser/kolab2/raw/contactMinimalTest.xml16
-rw-r--r--test/synckolab/parser/kolab2/raw/list.test.eml6
-rw-r--r--test/synckolab/parser/kolab2/raw/list.test.xml21
-rw-r--r--test/synckolab/parser/kolab2/raw/list.test2.eml (renamed from test/synckolab/parser/kolab2/raw/list.test2.xml)0
-rw-r--r--test/synckolab/parser/kolab2/raw/testcontact.eml (renamed from test/synckolab/parser/kolab2/raw/testcontact.xml)32
-rw-r--r--test/synckolab/parser/kolab3/calendarTest.js1
-rw-r--r--test/synckolab/parser/kolab3/contactTest.js38
-rw-r--r--test/synckolab/parser/kolab3/json/contact.complex.mime.json6
-rw-r--r--test/synckolab/parser/kolab3/xml/contact.complex.mime.xml1
14 files changed, 155 insertions, 76 deletions
diff --git a/test/synckolab/parser/kolab2/contactTest.js b/test/synckolab/parser/kolab2/contactTest.js
index 2ae83f1..99608a1 100644
--- a/test/synckolab/parser/kolab2/contactTest.js
+++ b/test/synckolab/parser/kolab2/contactTest.js
@@ -13,13 +13,15 @@ load("test/lib/testOverride.js");
test("skolab2 ynckolab.addressbookTools.parseMessageContent", function(){
equal(null, synckolab.addressbookTools.parseMessageContent(null), "parsing a null message");
- var testFiles = ["contactMinimalTest", "contactFullTest", "list.test", "list.test2"];
+ var testFiles = ["testcontact", "contactMinimalTest", "contactFullTest", "list.test", "list.test2"];
var content, entry, jsonEntry;
for(var i = 0; i < testFiles.length; i++) {
var src = testFiles[i];
+ print("INFO: KOLAB 2 TESTING CONTACT: " + src +"\n");
- content = readFile("test/synckolab/parser/kolab2/raw/"+src+".xml");
+ content = readFile("test/synckolab/parser/kolab2/raw/"+src+".eml");
+ content = synckolab.tools.stripMailHeader(content);
entry = synckolab.addressbookTools.parseMessageContent(content);
content = readFile("test/synckolab/parser/kolab2/json/"+src+".json");
jsonEntry = JSON.parse(content);
diff --git a/test/synckolab/parser/kolab2/json/list.test.json b/test/synckolab/parser/kolab2/json/list.test.json
index 8e1e3b6..1de61e9 100644
--- a/test/synckolab/parser/kolab2/json/list.test.json
+++ b/test/synckolab/parser/kolab2/json/list.test.json
@@ -2,20 +2,20 @@
"synckolab": "3.0.0",
"type": "maillist",
"isMailList": true,
- "ts": 1349908157804,
+ "ts": 1351253178012,
+ "UUID": "list_name",
"DisplayName": "list-name",
"Notes": "list-description",
"NickName": "list-nickname",
- "UUID": "SomeRandomUUID",
"contacts": [
{
"synckolab": "3.0.0",
"listMember": true,
"type": "contact",
"isMailList": false,
- "ts": 1349908157831,
+ "ts": 1351253178057,
"DisplayName": "testöä lastname",
- "PrimaryEmail": "weird@email.com",
+ "PrimaryEmail": "email@mail.com",
"UUID": "urn:uuid:pas-id-1D84CEA337CD1878"
},
{
@@ -23,11 +23,11 @@
"listMember": true,
"type": "contact",
"isMailList": false,
- "ts": 1349908157832,
+ "ts": 1351253178058,
"DisplayName": "cont2#öüä&$",
"PrimaryEmail": "weird@email.com",
"UUID": "urn:uuid:pas-id-A4E937D838A897AD"
}
],
"sha1": "8d2e5e0088530d5fbe9f6acc40a5e3eb2c094ec7"
-} \ No newline at end of file
+} \ No newline at end of file
diff --git a/test/synckolab/parser/kolab2/json/testcontact.json b/test/synckolab/parser/kolab2/json/testcontact.json
index a94b85d..1bc576b 100644
--- a/test/synckolab/parser/kolab2/json/testcontact.json
+++ b/test/synckolab/parser/kolab2/json/testcontact.json
@@ -4,28 +4,17 @@
"isMailList": false,
"ts": 1349214053542,
"UUID": "uid",
- "creation-date": "2004-05-04T15:00:00Z",
"FirstName": "(string, default empty)",
"LastName": "(string, default empty)",
"DisplayName": "(string, default empty)",
- "free-busy-url": "(string, default empty)",
"Company": "(string, default empty)",
"WebPage1": "(string, default empty)",
"AimScreenName": "(string, default empty)",
"Department": "(string, default empty)",
- "office-location": "(string, default empty)",
- "profession": "(string, default empty)",
"JobTitle": "(string, default empty)",
- "manager-name": "(string, default empty)",
- "assistant": "(string, default empty)",
"NickName": "(string, default empty)",
- "spouse-name": "(string, default empty)",
- "BirthYear": "(date, no default)",
- "AnniversaryYear": "(date, no default)",
"PhotoName": "(string(attachment filename), default empty)",
- "children": "(string, default empty)",
- "gender": "(string, default empty)",
- "language": "(string, default empty)",
+ "Profession": "(string, default empty)",
"CellularNumber": "(string, default empty)",
"PrimaryEmail": "(string, default empty)",
"HomeAddress": "(string, default empty)",
@@ -34,8 +23,5 @@
"HomeState": "(string, default empty)",
"HomeZipCode": "(string, default empty)",
"HomeCountry": "(string, default empty)",
- "preferred-address": "(string, default none)",
- "latitude": "3.23",
- "longitude": "5.222",
"sha1": "9bd2adac4fdeb9e44eb5c2f05d2a5458a9170703"
} \ No newline at end of file
diff --git a/test/synckolab/parser/kolab2/raw/contactFullTest.xml b/test/synckolab/parser/kolab2/raw/contactFullTest.eml
index b0eaa88..bbfabdf 100644
--- a/test/synckolab/parser/kolab2/raw/contactFullTest.xml
+++ b/test/synckolab/parser/kolab2/raw/contactFullTest.eml
@@ -1,5 +1,31 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<contact version="1.0" >
+Date: Fri, 27 Apr 2012 02:25:38 +0200
+X-Kolab-Type: application/x-vnd.kolab.contact
+X-Kolab-Mime-Version: 3.0
+User-Agent: Libkolab-0.2.0
+Content-Type: multipart/mixed; boundary="nextPart38186565.1WqI9LYOEs"
+Subject: Huu5X7hfYy
+From: Displayname <first@email.org>
+MIME-Version: 1.0
+
+
+--nextPart38186565.1WqI9LYOEs
+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/kolab2-clients.html
+
+--Boundary-00=6988F02CCC809628
+Content-Type: application/x-vnd.kolab.contact;
+ name="kolab.xml"
+Content-Transfer-Encoding: quoted-printable
+Content-Disposition: attachment;
+ filename="kolab.xml"
+
+<?xml version=3D"1.0" encoding=3D"UTF-8"?>
+<contact version=3D"1.0" >
<product-id>SyncKolab, Kolab resource</product-id>
<uid>pas-id-1D84CEA337CD1878</uid>
<last-modification-date>2012-07-04T10:45:33Z</last-modification-date>
@@ -38,7 +64,7 @@ note with öäü!</body>
<type>page</type>
<number>01-page</number>
</phone>
- <email type="primary">
+ <email type=3D"primary">
<display-name>testöä lastname</display-name>
<smtp-address>email@mail.com</smtp-address>
</email>
@@ -69,3 +95,4 @@ note with öäü!</body>
<custom3>cust3</custom3>
<allow-remote-content>true</allow-remote-content>
</contact>
+--Boundary-00=6988F02CCC809628-- \ No newline at end of file
diff --git a/test/synckolab/parser/kolab2/raw/contactMinimalTest.eml b/test/synckolab/parser/kolab2/raw/contactMinimalTest.eml
new file mode 100644
index 0000000..675157d
--- /dev/null
+++ b/test/synckolab/parser/kolab2/raw/contactMinimalTest.eml
@@ -0,0 +1,43 @@
+Date: Fri, 27 Apr 2012 02:25:38 +0200
+X-Kolab-Type: application/x-vnd.kolab.contact
+X-Kolab-Mime-Version: 3.0
+User-Agent: Libkolab-0.2.0
+Content-Type: multipart/mixed; boundary="nextPart38186565.1WqI9LYOEs"
+Subject: Huu5X7hfYy
+From: Displayname <first@email.org>
+MIME-Version: 1.0
+
+
+--nextPart38186565.1WqI9LYOEs
+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/kolab2-clients.html
+
+--Boundary-00=6988F02CCC809628
+Content-Type: application/x-vnd.kolab.contact;
+ name="kolab.xml"
+Content-Transfer-Encoding: quoted-printable
+Content-Disposition: attachment;
+ filename="kolab.xml"
+
+<?xml version=3D"1.0" encoding=3D"UTF-8"?>
+<contact version=3D"1.0" >
+ <product-id>SyncKolab, Kolab resource</product-id>
+ <uid>sk-vc-C18A6B3AE0CD9EDC</uid>
+ <last-modification-date>2012-07-04T10:45:33Z</last-modification-date>
+ <sensitivity>public</sensitivity>
+ <name>
+ <given-name>Test</given-name>
+ <last-name>LastName</last-name>
+ <full-name>Test Lastname</full-name>
+ </name>
+ <email type=3D"primary">
+ <smtp-address>email@test.com</smtp-address>
+ </email>
+ <allow-remote-content>true</allow-remote-content>
+</contact>
+--Boundary-00=6988F02CCC809628-- \ No newline at end of file
diff --git a/test/synckolab/parser/kolab2/raw/contactMinimalTest.xml b/test/synckolab/parser/kolab2/raw/contactMinimalTest.xml
deleted file mode 100644
index 3e1221a..0000000
--- a/test/synckolab/parser/kolab2/raw/contactMinimalTest.xml
+++ /dev/null
@@ -1,16 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<contact version="1.0" >
- <product-id>SyncKolab, Kolab resource</product-id>
- <uid>sk-vc-C18A6B3AE0CD9EDC</uid>
- <last-modification-date>2012-07-04T10:45:33Z</last-modification-date>
- <sensitivity>public</sensitivity>
- <name>
- <given-name>Test</given-name>
- <last-name>LastName</last-name>
- <full-name>Test Lastname</full-name>
- </name>
- <email type="primary">
- <smtp-address>email@test.com</smtp-address>
- </email>
- <allow-remote-content>true</allow-remote-content>
-</contact>
diff --git a/test/synckolab/parser/kolab2/raw/list.test.eml b/test/synckolab/parser/kolab2/raw/list.test.eml
index 9963cd3..8d09f34 100644
--- a/test/synckolab/parser/kolab2/raw/list.test.eml
+++ b/test/synckolab/parser/kolab2/raw/list.test.eml
@@ -1,4 +1,4 @@
-From: niko.berger@corinis.com
+From: owner@no.tld
Reply-To:
Bcc:
To: synckolab@no.tld
@@ -22,8 +22,8 @@ Name: list-name
Notes: list-description
Members:
-test lastname <email@mail.com>
-cont2#&$ <weird@email.com>
+test�� lastname <email@mail.com>
+cont2#���&$ <weird@email.com>
---
Notice:
diff --git a/test/synckolab/parser/kolab2/raw/list.test.xml b/test/synckolab/parser/kolab2/raw/list.test.xml
deleted file mode 100644
index 9f07b00..0000000
--- a/test/synckolab/parser/kolab2/raw/list.test.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<distribution-list version="1.0" >
- <product-id>SyncKolab, Kolab resource</product-id>
- <uid>list_name</uid>
- <creation-date>20121017T214612Z</creation-date>
- <last-modification-date>1970-01-01T00:00:00Z</last-modification-date>
- <sensitivity>public</sensitivity>
- <name>list-name</name>
- <body>list-description</body>
- <nickname>list-nickname</nickname>
- <member>
- <display-name>testöä lastname</display-name>
- <smtp-address>weird@email.com</smtp-address>
- <uid>urn:uuid:pas-id-1D84CEA337CD1878</uid>
- </member>
- <member>
- <display-name>cont2#öüä&amp;$</display-name>
- <smtp-address>weird@email.com</smtp-address>
- <uid>urn:uuid:pas-id-A4E937D838A897AD</uid>
- </member>
-</distribution-list>
diff --git a/test/synckolab/parser/kolab2/raw/list.test2.xml b/test/synckolab/parser/kolab2/raw/list.test2.eml
index dfb734d..dfb734d 100644
--- a/test/synckolab/parser/kolab2/raw/list.test2.xml
+++ b/test/synckolab/parser/kolab2/raw/list.test2.eml
diff --git a/test/synckolab/parser/kolab2/raw/testcontact.xml b/test/synckolab/parser/kolab2/raw/testcontact.eml
index 95ca60c..c3343c7 100644
--- a/test/synckolab/parser/kolab2/raw/testcontact.xml
+++ b/test/synckolab/parser/kolab2/raw/testcontact.eml
@@ -1,5 +1,32 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<contact version="3.0dev1" xmlns="http://kolab.org">
+From: owner@no.tld
+Reply-To:
+Bcc:
+To: synckolab@no.tld
+Subject: list_name
+Date: Thu, 11 Oct 2012 00:20:52 +0200
+Content-Type: Multipart/Mixed;boundary="Boundary-00=173882C61DEE82C7"
+User-Agent: SyncKolab 2.9.0
+X-Kolab-Type: application/x-vnd.kolab.contact.distlist
+
+--Boundary-00=173882C61DEE82C7
+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/kolab2-clients.html
+
+--Boundary-00=173882C61DEE82C7
+Content-Type: application/x-vnd.kolab.contact;
+ name="kolab.xml"
+Content-Transfer-Encoding: base64
+Content-Disposition: attachment;
+ filename="kolab.xml"
+
+<?xml version=3D"1.0" encoding=3D"UTF-8"?>
+<contact version=3D"3.0dev1" xmlns=3D"http://kolab.org">
<!-- Common fields -->
<uid>uid</uid>
<body></body>
@@ -58,3 +85,4 @@
<longitude>5.222</longitude>
</contact>
+--Boundary-00=173882C61DEE82C7-- \ No newline at end of file
diff --git a/test/synckolab/parser/kolab3/calendarTest.js b/test/synckolab/parser/kolab3/calendarTest.js
index 7e9f38d..e3c912b 100644
--- a/test/synckolab/parser/kolab3/calendarTest.js
+++ b/test/synckolab/parser/kolab3/calendarTest.js
@@ -18,6 +18,7 @@ test("kolab3 synckolab.addressbookTools.parseMessageContent", function(){
for(var i = 0; i < testFiles.length; i++) {
var src = testFiles[i];
+ print("INFO: KOLAB 3 TESTING - EVENT: " + src +"\n")
content = readFile("test/synckolab/parser/kolab3/raw/"+src);
content = synckolab.tools.stripMailHeader(content);
diff --git a/test/synckolab/parser/kolab3/contactTest.js b/test/synckolab/parser/kolab3/contactTest.js
index b697529..3a66a08 100644
--- a/test/synckolab/parser/kolab3/contactTest.js
+++ b/test/synckolab/parser/kolab3/contactTest.js
@@ -18,16 +18,13 @@ test("kolab3 synckolab.addressbookTools.parseMessageContent", function(){
for(var i = 0; i < testFiles.length; i++) {
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);
entry = synckolab.addressbookTools.parseMessageContent(content);
- if(entry.isMailList) {
- print(entry.toSource());
- }
content = readFile("test/synckolab/parser/kolab3/json/"+src+".json");
jsonEntry = JSON.parse(content);
- equal(synckolab.tools.equalsObject(entry, jsonEntry), true, src);
+ equal(synckolab.tools.equalsObject(entry, jsonEntry), true, "Json object compare: " + src);
// json -> kolab 3 xml
if(entry.type === "maillist") {
@@ -39,10 +36,39 @@ test("kolab3 synckolab.addressbookTools.parseMessageContent", function(){
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);
var diff = diffString(xmlcontent, content);
- print("DIFF FOUND:"+ xmlcontent.replace(/[\n\r\t ]/g, "").length + " vs. "+ content.replace(/[\n\r\t ]/g, "").length +"\n" + diff);
+ print("ERROR: DIFF FOUND:"+ xmlcontent.replace(/[\n\r\t ]/g, "").length + " vs. "+ content.replace(/[\n\r\t ]/g, "").length +"\n" + diff);
}
}
});
+
+/*
+var testFiles = ["contact.complex.mime"];
+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);
+ entry = synckolab.addressbookTools.parseMessageContent(content);
+ if(entry.isMailList) {
+ print(entry.toSource());
+ }
+ content = readFile("test/synckolab/parser/kolab3/json/"+src+".json");
+ jsonEntry = JSON.parse(content);
+
+ // json -> kolab 3 xml
+ if(entry.type === "maillist") {
+ content = synckolab.addressbookTools.list2Kolab3(entry);
+ } else {
+ content = synckolab.addressbookTools.card2Kolab3(entry);
+ }
+ 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);
+ var diff = diffString(xmlcontent, content);
+ 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"];
diff --git a/test/synckolab/parser/kolab3/json/contact.complex.mime.json b/test/synckolab/parser/kolab3/json/contact.complex.mime.json
index 9745af3..c2cb6d0 100644
--- a/test/synckolab/parser/kolab3/json/contact.complex.mime.json
+++ b/test/synckolab/parser/kolab3/json/contact.complex.mime.json
@@ -9,8 +9,10 @@
"LastName": "Firstname",
"Notes": "Notes",
"JobTitle": "Title",
- "PhotoType": "inline:image/png",
- "PhotoData": "iVBORw0KGgoAAAANSUhEUgAAAGQAAABkCAYAAABw4pVUAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAAOTQAADpwB3vacVwAABAVJREFUeJztncFrFGcYxt/szLrJmk2yWTeojQktQluiqNFeKglSQmsOHhRyUApKPbeHQC8taKl4E0Hw4sGToAcvgojVQCg0B+2ph0DprTlYs7SQsNlkdzKzmf4DzxvYsCRP9Pkdn5n53iG/fPDy7TczZkIIIYQQov107PQNtI0vrR/mOfveveap/eAcSXeqRsYdSOwIEkKGhJAhIWRICBkSQsbua3u/slEUj346OoPyUrGEW1Uzm5mfycMDNRtB8ciHIy9RXswXi16NuYU5XOOx1VGsGUKGhJAhIWRICBkSQka40zfgcs6uoHjis4l7KB8fG8+ifPa3Wb9GZJdRPHZq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Bnl9R3pfthOebmS1nl/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/xml/contact.complex.mime.xml b/test/synckolab/parser/kolab3/xml/contact.complex.mime.xml
index d6a1683..4eab87d 100644
--- a/test/synckolab/parser/kolab3/xml/contact.complex.mime.xml
+++ b/test/synckolab/parser/kolab3/xml/contact.complex.mime.xml
@@ -76,6 +76,7 @@
<email>
<text>second@email.org</text>
</email>
+ <x-custom><identifier>Profession</identifier><value>Profession</value></x-custom>
<x-custom><identifier>X-AllowRemoteContent</identifier><value>true</value></x-custom>
</vcard>
</vcards> \ No newline at end of file