kopia lustrzana https://github.com/collective/icalendar
allow dots in property names
rodzic
75f2819bfc
commit
188ee26070
|
|
@ -5,16 +5,20 @@ Changelog
|
||||||
3.8 (unreleased)
|
3.8 (unreleased)
|
||||||
----------------
|
----------------
|
||||||
|
|
||||||
|
- Allow dots in property names. Refs #143.
|
||||||
|
[untitaker]
|
||||||
|
|
||||||
- Change class representation for CaselessDict objects to always include the
|
- Change class representation for CaselessDict objects to always include the
|
||||||
class name or the class' name attribute, if available. Also show
|
class name or the class' name attribute, if available. Also show
|
||||||
subcomponents for Component objects.
|
subcomponents for Component objects.
|
||||||
[thet]
|
[thet]
|
||||||
|
|
||||||
- Don't use data_encode for CaselessDict class representation but use dict's
|
- Don't use data_encode for CaselessDict class representation but use dict's
|
||||||
__repr__ method.
|
__repr__ method.
|
||||||
[t-8ch]
|
[t-8ch]
|
||||||
|
|
||||||
- Handle parameters with multiple values, which is needed for VCard 3.0.
|
- Handle parameters with multiple values, which is needed for VCard 3.0.
|
||||||
|
Refs #142.
|
||||||
[t-8ch]
|
[t-8ch]
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -293,3 +293,26 @@ END:VCALENDAR"""
|
||||||
ctl.parts(),
|
ctl.parts(),
|
||||||
(u'TEL', Parameters({'TYPE': ['HOME', 'VOICE']}), u'000000000'),
|
(u'TEL', Parameters({'TYPE': ['HOME', 'VOICE']}), u'000000000'),
|
||||||
)
|
)
|
||||||
|
|
||||||
|
def test_issue_143(self):
|
||||||
|
"""Issue #143 - Allow dots in property names.
|
||||||
|
Another vCard related issue.
|
||||||
|
https://github.com/collective/icalendar/pull/143
|
||||||
|
"""
|
||||||
|
from icalendar.parser import Contentline, Parameters
|
||||||
|
|
||||||
|
ctl = Contentline.from_ical("ITEMADRNULLTHISISTHEADRESS08158SOMECITY12345.ADR:;;This is the Adress 08; Some City;;12345;Germany") # nopep8
|
||||||
|
self.assertEqual(
|
||||||
|
ctl.parts(),
|
||||||
|
(u'ITEMADRNULLTHISISTHEADRESS08158SOMECITY12345.ADR',
|
||||||
|
Parameters(),
|
||||||
|
u';;This is the Adress 08; Some City;;12345;Germany'),
|
||||||
|
)
|
||||||
|
|
||||||
|
ctl2 = Contentline.from_ical("ITEMADRNULLTHISISTHEADRESS08158SOMECITY12345.X-ABLABEL:") # nopep8
|
||||||
|
self.assertEqual(
|
||||||
|
ctl2.parts(),
|
||||||
|
(u'ITEMADRNULLTHISISTHEADRESS08158SOMECITY12345.X-ABLABEL',
|
||||||
|
Parameters(),
|
||||||
|
u''),
|
||||||
|
)
|
||||||
|
|
|
||||||
Ładowanie…
Reference in New Issue