mirror of
https://github.com/samsonjs/vdirsyncer.git
synced 2026-03-25 08:55:50 +00:00
Remove VERSION from ignored props, more tests
This commit is contained in:
parent
27345add6d
commit
fd3d81e925
2 changed files with 12 additions and 3 deletions
|
|
@ -127,10 +127,21 @@ def test_split_collection_timezones():
|
|||
assert given == expected
|
||||
|
||||
|
||||
def test_split_contacts():
|
||||
bare = '\r\n'.join([VCARD_TEMPLATE.format(r=x, uid=x) for x in range(4)])
|
||||
with_wrapper = 'BEGIN:VADDRESSBOOK\r\n' + bare + '\nEND:VADDRESSBOOK\r\n'
|
||||
|
||||
for x in (bare, with_wrapper):
|
||||
split = list(vobject.split_collection(bare))
|
||||
assert len(split) == 4
|
||||
assert vobject.join_collection(split).splitlines() == \
|
||||
with_wrapper.splitlines()
|
||||
|
||||
|
||||
def test_hash_item():
|
||||
a = EVENT_TEMPLATE.format(r=1, uid=1)
|
||||
b = u'\n'.join(line for line in a.splitlines()
|
||||
if u'PRODID' not in line and u'VERSION' not in line)
|
||||
if u'PRODID' not in line)
|
||||
assert vobject.hash_item(a) == vobject.hash_item(b)
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -18,8 +18,6 @@ def _process_properties(*s):
|
|||
IGNORE_PROPS = _process_properties(
|
||||
# PRODID is changed by radicale for some reason after upload
|
||||
'PRODID',
|
||||
# VERSION can get lost in singlefile storage
|
||||
'VERSION',
|
||||
# X-RADICALE-NAME is used by radicale, because hrefs don't really exist in
|
||||
# their filesystem backend
|
||||
'X-RADICALE-NAME',
|
||||
|
|
|
|||
Loading…
Reference in a new issue