summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Bruederli <bruederli@kolabsys.com>2013-07-24 17:01:23 (GMT)
committerThomas Bruederli <bruederli@kolabsys.com>2013-07-24 17:01:23 (GMT)
commitadff720d390cbd6efde8076e612621d0e36b164e (patch)
treee56f18fed9b41e8eb95a8369eef9c88689b6331c
parentee67f6c3050480f7d4f4f0ba663b49bdb3d86de8 (diff)
downloadiRony-adff720d390cbd6efde8076e612621d0e36b164e.tar.gz
Add tests for attachment support
-rw-r--r--test/README.md2
-rw-r--r--test/Resource/CalDAV/attachments/1.ics90
-rw-r--r--test/Resource/CalDAV/attachments/2.ics87
-rw-r--r--test/Resource/CalDAV/attachments/3.ics13
-rw-r--r--test/Resource/CalDAV/attachments/4.ics12
-rwxr-xr-xtest/runtests.sh3
-rw-r--r--test/scripts/tests/CalDAV/attachments.xml138
-rw-r--r--test/serverinfo.xml2
8 files changed, 344 insertions, 3 deletions
diff --git a/test/README.md b/test/README.md
index 296974d..d405c28 100644
--- a/test/README.md
+++ b/test/README.md
@@ -40,7 +40,7 @@ as well as the values of the following substitution keys:
Make sure that two users matching the patterns of $userid%d and subsequent do
exist on the Kolab server that is to be tested with. Default user accounts
-are set to dav.user01@<domain> and dav.user02@<domain> with password "12345".
+are set to dav.user01@example.org and dav.user02@example.org with password "12345".
Running the Tests
diff --git a/test/Resource/CalDAV/attachments/1.ics b/test/Resource/CalDAV/attachments/1.ics
new file mode 100644
index 0000000..96b7d27
--- /dev/null
+++ b/test/Resource/CalDAV/attachments/1.ics
@@ -0,0 +1,90 @@
+BEGIN:VCALENDAR
+VERSION:2.0
+CALSCALE:GREGORIAN
+PRODID:-//Example Inc.//Example Calendar//EN
+BEGIN:VEVENT
+SUMMARY:New Event
+DTSTART;TZID=America/Vancouver:$now.year.1:0709T133000
+DTEND;TZID=America/Vancouver:$now.year.1:0709T143000
+DTSTAMP:20060710T225223Z
+UID:1
+CLASS:PUBLIC
+TRANSP:OPAQUE
+ATTACH;FMT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AFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAU
+ UUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRR
+ RQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFF
+ ABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUA
+ FFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAU
+ UUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRR
+ RQAUUUUAFFFFAH//2Q==
+END:VEVENT
+END:VCALENDAR
diff --git a/test/Resource/CalDAV/attachments/2.ics b/test/Resource/CalDAV/attachments/2.ics
new file mode 100644
index 0000000..31e3505
--- /dev/null
+++ b/test/Resource/CalDAV/attachments/2.ics
@@ -0,0 +1,87 @@
+BEGIN:VCALENDAR
+VERSION:2.0
+CALSCALE:GREGORIAN
+PRODID:-//Example Inc.//Example Calendar//EN
+BEGIN:VTODO
+DTSTAMP:20060313T145240Z
+SUMMARY:Task #1
+UID:2
+CLASS:PUBLIC
+ATTACH;FMTTYPE=image/jpeg;ENCODING=BASE64;VALUE=BINARY;X-LABEL=task.jpg:
+ /9j/4AAQSkZJRgABAQEASABIAAD/2wBDAAMCAgMCAgMDAwMEAwMEBQgFBQQEBQoHBwYIDAoMDAsK
+ CwsNDhIQDQ4RDgsLEBYQERMUFRUVDA8XGBYUGBIUFRT/2wBDAQMEBAUEBQkFBQkUDQsNFBQUFBQU
+ FBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBT/wAARCAEAAQADASIA
+ AhEBAxEB/8QAHwAAAQUBAQEBAQEAAAAAAAAAAAECAwQFBgcICQoL/8QAtRAAAgEDAwIEAwUFBAQA
+ AAF9AQIDAAQRBRIhMUEGE1FhByJxFDKBkaEII0KxwRVS0fAkM2JyggkKFhcYGRolJicoKSo0NTY3
+ ODk6Q0RFRkdISUpTVFVWV1hZWmNkZWZnaGlqc3R1dnd4eXqDhIWGh4iJipKTlJWWl5iZmqKjpKWm
+ p6ipqrKztLW2t7i5usLDxMXGx8jJytLT1NXW19jZ2uHi4+Tl5ufo6erx8vP09fb3+Pn6/8QAHwEA
+ AwEBAQEBAQEBAQAAAAAAAAECAwQFBgcICQoL/8QAtREAAgECBAQDBAcFBAQAAQJ3AAECAxEEBSEx
+ BhJBUQdhcRMiMoEIFEKRobHBCSMzUvAVYnLRChYkNOEl8RcYGRomJygpKjU2Nzg5OkNERUZHSElK
+ U1RVVldYWVpjZGVmZ2hpanN0dXZ3eHl6goOEhYaHiImKkpOUlZaXmJmaoqOkpaanqKmqsrO0tba3
+ uLm6wsPExcbHyMnK0tPU1dbX2Nna4uPk5ebn6Onq8vP09fb3+Pn6/9oADAMBAAIRAxEAPwD6Iooo
+ r9zP5sCiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigA
+ ooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACi
+ iigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKK
+ KACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAoooo
+ AKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooA8S/al+JPxE+Gvh3Rbr4d+HG8R31
+ zdNFdRLp0155cYTIbbEQV54ya+StQ/b4+Nmk67/Yl94b0iy1nekf9nXGk3MdxvcAovlmXdlgykDH
+ ORjrX6RV+Yf7Q/8Ayfy//Yb0b/0Ta18pnPt6HLWpVWlJpW6LR/5H2/D/ANWxPNh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UAFFFFABRRRQAUUUUAFFFFABRRRQAU
+ UUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRR
+ RQAUUUUAFFFFAH//2Q==
+END:VTODO
+END:VCALENDAR
diff --git a/test/Resource/CalDAV/attachments/3.ics b/test/Resource/CalDAV/attachments/3.ics
new file mode 100644
index 0000000..0235680
--- /dev/null
+++ b/test/Resource/CalDAV/attachments/3.ics
@@ -0,0 +1,13 @@
+BEGIN:VCALENDAR
+VERSION:2.0
+CALSCALE:GREGORIAN
+PRODID:-//Example Inc.//Example Calendar//EN
+BEGIN:VEVENT
+SUMMARY:New Event
+DURATION:PT1H
+DTSTART;TZID=America/Vancouver:$now.year.1:0709T133000
+DTSTAMP:20060710T225223Z
+UID:3
+ATTACH:http://www.example.com/test.jpg
+END:VEVENT
+END:VCALENDAR
diff --git a/test/Resource/CalDAV/attachments/4.ics b/test/Resource/CalDAV/attachments/4.ics
new file mode 100644
index 0000000..d78996d
--- /dev/null
+++ b/test/Resource/CalDAV/attachments/4.ics
@@ -0,0 +1,12 @@
+BEGIN:VCALENDAR
+VERSION:2.0
+CALSCALE:GREGORIAN
+PRODID:-//Example Inc.//Example Calendar//EN
+BEGIN:VTODO
+DTSTAMP:20060313T145240Z
+STATUS:NEEDS-ACTION
+SUMMARY:Task #1
+UID:4
+ATTACH:http://www.example.com/test.jpg
+END:VTODO
+END:VCALENDAR
diff --git a/test/runtests.sh b/test/runtests.sh
index f4b4160..951c32f 100755
--- a/test/runtests.sh
+++ b/test/runtests.sh
@@ -26,6 +26,7 @@ export PYTHONPATH="$PYTHONPATH:$CALDAVTESTER/../pycalendar/src"
$CALDAVTESTER/testcaldav.py --print-details-onfail -s serverinfo.xml \
CalDAV/current-user-principal.xml \
CalDAV/caldavIOP.xml \
- CalDAV/ctag.xml
+ CalDAV/ctag.xml \
+ CalDAV/attachments.xml
diff --git a/test/scripts/tests/CalDAV/attachments.xml b/test/scripts/tests/CalDAV/attachments.xml
new file mode 100644
index 0000000..028a88c
--- /dev/null
+++ b/test/scripts/tests/CalDAV/attachments.xml
@@ -0,0 +1,138 @@
+<?xml version="1.0" standalone="no"?>
+
+<!DOCTYPE caldavtest SYSTEM "caldavtest.dtd">
+
+<!--
+ Copyright (c) 2006-2013 Apple Inc. All rights reserved.
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<caldavtest>
+ <description>Test attachments with CalDAV</description>
+
+ <require-feature>
+ <feature>caldav</feature>
+ </require-feature>
+
+ <start/>
+
+ <test-suite name='Inline' ignore='no'>
+ <test name='1' ignore='no'>
+ <description>VEVENT with image/jpeg</description>
+ <request end-delete='yes'>
+ <method>PUT</method>
+ <ruri>$calendarpath1:/1.ics</ruri>
+ <data>
+ <content-type>text/calendar; charset=utf-8</content-type>
+ <filepath>Resource/CalDAV/attachments/1.ics</filepath>
+ </data>
+ <verify>
+ <callback>statusCode</callback>
+ </verify>
+ </request>
+ <request>
+ <method>GET</method>
+ <ruri>$calendarpath1:/1.ics</ruri>
+ <verify>
+ <callback>calendarDataMatch</callback>
+ <arg>
+ <name>filepath</name>
+ <value>Resource/CalDAV/attachments/1.ics</value>
+ </arg>
+ </verify>
+ </request>
+ </test>
+ <test name='2' ignore='no'>
+ <description>VTODO with image/jpeg</description>
+ <request end-delete='yes'>
+ <method>PUT</method>
+ <ruri>$taskspath1:/2.ics</ruri>
+ <data>
+ <content-type>text/calendar; charset=utf-8</content-type>
+ <filepath>Resource/CalDAV/attachments/2.ics</filepath>
+ </data>
+ <verify>
+ <callback>statusCode</callback>
+ </verify>
+ </request>
+ <request>
+ <method>GET</method>
+ <ruri>$taskspath1:/2.ics</ruri>
+ <verify>
+ <callback>calendarDataMatch</callback>
+ <arg>
+ <name>filepath</name>
+ <value>Resource/CalDAV/attachments/2.ics</value>
+ </arg>
+ </verify>
+ </request>
+ </test>
+ </test-suite>
+
+ <test-suite name='External' ignore='no'>
+ <test name='1' ignore='no'>
+ <description>VEVENT with http://</description>
+ <request end-delete='yes'>
+ <method>PUT</method>
+ <ruri>$calendarpath1:/3.ics</ruri>
+ <data>
+ <content-type>text/calendar; charset=utf-8</content-type>
+ <filepath>Resource/CalDAV/attachments/3.ics</filepath>
+ </data>
+ <verify>
+ <callback>statusCode</callback>
+ </verify>
+ </request>
+ <request>
+ <method>GET</method>
+ <ruri>$calendarpath1:/3.ics</ruri>
+ <verify>
+ <callback>dataString</callback>
+ <arg>
+ <name>contains</name>
+ <value>ATTACH:http://www.example.com/test.jpg</value>
+ </arg>
+ </verify>
+ </request>
+ </test>
+ <test name='2' ignore='no'>
+ <description>VTODO with image/jpeg</description>
+ <request end-delete='yes'>
+ <method>PUT</method>
+ <ruri>$taskspath1:/4.ics</ruri>
+ <data>
+ <content-type>text/calendar; charset=utf-8</content-type>
+ <filepath>Resource/CalDAV/attachments/4.ics</filepath>
+ </data>
+ <verify>
+ <callback>statusCode</callback>
+ </verify>
+ </request>
+ <request>
+ <method>GET</method>
+ <ruri>$taskspath1:/4.ics</ruri>
+ <verify>
+ <callback>dataString</callback>
+ <arg>
+ <name>contains</name>
+ <value>ATTACH:http://www.example.com/test.jpg</value>
+ </arg>
+ </verify>
+ </request>
+ </test>
+ </test-suite>
+
+ <end/>
+
+</caldavtest>
diff --git a/test/serverinfo.xml b/test/serverinfo.xml
index 30c4df3..501e275 100644
--- a/test/serverinfo.xml
+++ b/test/serverinfo.xml
@@ -409,7 +409,7 @@
<!-- user id -->
<substitution>
<key>$userid%d:</key>
- <value>dav.user%02d@brotherli.ch</value>
+ <value>dav.user%02d@example.org</value>
</substitution>
<!-- user guid -->
<substitution>