From b9f3ca35819e51059ed719106f20c2c1368eeb5b Mon Sep 17 00:00:00 2001 From: Markus Unterwaditzer Date: Fri, 29 Apr 2016 19:47:48 +0200 Subject: [PATCH] Fix hypothesis metadata tests --- tests/test_metasync.py | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/tests/test_metasync.py b/tests/test_metasync.py index 31ba2e9..19fabca 100644 --- a/tests/test_metasync.py +++ b/tests/test_metasync.py @@ -6,6 +6,7 @@ import hypothesis.strategies as st import pytest from vdirsyncer.metasync import MetaSyncConflict, metasync +from vdirsyncer.storage.base import normalize_meta_value from vdirsyncer.storage.memory import MemoryStorage from . import blow_up @@ -88,11 +89,8 @@ def test_conflict_x_wins(wins): keys = st.text(min_size=1).filter(lambda x: x.strip() == x) - -metadata = st.dictionaries( - keys, - st.text() -) +values = st.text().filter(lambda x: normalize_meta_value(x) == x) +metadata = st.dictionaries(keys, values) @given(