1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/tests/templates/event-request-conflict.txt Mon May 18 17:14:02 2015 +0200
1.3 @@ -0,0 +1,34 @@
1.4 +Content-Type: multipart/alternative; boundary="===============0047278175=="
1.5 +MIME-Version: 1.0
1.6 +From: paul.boddie@example.com
1.7 +To: resource-room-confroom@example.com
1.8 +Subject: Invitation!
1.9 +
1.10 +--===============0047278175==
1.11 +Content-Type: text/plain; charset="us-ascii"
1.12 +MIME-Version: 1.0
1.13 +Content-Transfer-Encoding: 7bit
1.14 +
1.15 +This message contains an event.
1.16 +--===============0047278175==
1.17 +MIME-Version: 1.0
1.18 +Content-Transfer-Encoding: 7bit
1.19 +Content-Type: text/calendar; charset="us-ascii"; method="REQUEST"
1.20 +
1.21 +BEGIN:VCALENDAR
1.22 +PRODID:-//imip-agent/test//EN
1.23 +METHOD:REQUEST
1.24 +VERSION:2.0
1.25 +BEGIN:VEVENT
1.26 +ORGANIZER:mailto:paul.boddie@example.com
1.27 +ATTENDEE;ROLE=CHAIR:mailto:paul.boddie@example.com
1.28 +ATTENDEE;RSVP=TRUE:mailto:resource-room-confroom@example.com
1.29 +DTSTAMP:20141125T004600Z
1.30 +DTSTART;TZID=Europe/Oslo:20141126T160000
1.31 +DTEND;TZID=Europe/Oslo:20141126T170000
1.32 +SUMMARY:A conflicting meeting at 4pm
1.33 +UID:event2@example.com
1.34 +END:VEVENT
1.35 +END:VCALENDAR
1.36 +
1.37 +--===============0047278175==--
2.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2.2 +++ b/tests/templates/event-request.txt Mon May 18 17:14:02 2015 +0200
2.3 @@ -0,0 +1,34 @@
2.4 +Content-Type: multipart/alternative; boundary="===============0047278175=="
2.5 +MIME-Version: 1.0
2.6 +From: paul.boddie@example.com
2.7 +To: resource-room-confroom@example.com
2.8 +Subject: Invitation!
2.9 +
2.10 +--===============0047278175==
2.11 +Content-Type: text/plain; charset="us-ascii"
2.12 +MIME-Version: 1.0
2.13 +Content-Transfer-Encoding: 7bit
2.14 +
2.15 +This message contains an event.
2.16 +--===============0047278175==
2.17 +MIME-Version: 1.0
2.18 +Content-Transfer-Encoding: 7bit
2.19 +Content-Type: text/calendar; charset="us-ascii"; method="REQUEST"
2.20 +
2.21 +BEGIN:VCALENDAR
2.22 +PRODID:-//imip-agent/test//EN
2.23 +METHOD:REQUEST
2.24 +VERSION:2.0
2.25 +BEGIN:VEVENT
2.26 +ORGANIZER:mailto:paul.boddie@example.com
2.27 +ATTENDEE;ROLE=CHAIR:mailto:paul.boddie@example.com
2.28 +ATTENDEE;RSVP=TRUE:mailto:resource-room-confroom@example.com
2.29 +DTSTAMP:20141125T004600Z
2.30 +DTSTART;TZID=Europe/Oslo:20141126T160000
2.31 +DTEND;TZID=Europe/Oslo:20141126T170000
2.32 +SUMMARY:Meeting at 4pm
2.33 +UID:event1@example.com
2.34 +END:VEVENT
2.35 +END:VCALENDAR
2.36 +
2.37 +--===============0047278175==--
3.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
3.2 +++ b/tests/templates/fb-request.txt Mon May 18 17:14:02 2015 +0200
3.3 @@ -0,0 +1,31 @@
3.4 +Content-Type: multipart/alternative; boundary="===============0945993647=="
3.5 +MIME-Version: 1.0
3.6 +From: paul.boddie@example.com
3.7 +To: resource-room-confroom@example.com
3.8 +
3.9 +--===============0945993647==
3.10 +Content-Type: text/plain; charset="us-ascii"
3.11 +MIME-Version: 1.0
3.12 +Content-Transfer-Encoding: 7bit
3.13 +
3.14 +This message contains a free/busy request.
3.15 +--===============0945993647==
3.16 +Content-Type: text/calendar; charset="us-ascii"; method="REQUEST"
3.17 +MIME-Version: 1.0
3.18 +Content-Transfer-Encoding: 7bit
3.19 +
3.20 +BEGIN:VCALENDAR
3.21 +PRODID:-//imip-agent/test//EN
3.22 +METHOD:REQUEST
3.23 +VERSION:2.0
3.24 +BEGIN:VFREEBUSY
3.25 +ORGANIZER:mailto:paul.boddie@example.com
3.26 +ATTENDEE:mailto:resource-room-confroom@example.com
3.27 +DTSTAMP:20141125T164400Z
3.28 +DTSTART:20141126T150000Z
3.29 +DTEND:20141126T180000Z
3.30 +UID:fb1@example.com
3.31 +END:VFREEBUSY
3.32 +END:VCALENDAR
3.33 +
3.34 +--===============0945993647==--
4.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
4.2 +++ b/tools/showmail.py Mon May 18 17:14:02 2015 +0200
4.3 @@ -0,0 +1,17 @@
4.4 +from email import message_from_file
4.5 +import sys
4.6 +
4.7 +def decode(part):
4.8 + for key, value in part.items():
4.9 + print "%s: %s" % (key, value)
4.10 + print
4.11 + decoded = part.get_payload(decode=True)
4.12 + if decoded:
4.13 + print decoded
4.14 + print
4.15 + else:
4.16 + for part in part.get_payload():
4.17 + decode(part)
4.18 +
4.19 +message = message_from_file(sys.stdin)
4.20 +decode(message)