Fix TestDict.test_hypothesis_text for unordered dicts
This commit is contained in:
parent
ea2b9f5596
commit
05f4f2e742
@ -1471,10 +1471,13 @@ class TestDict:
|
||||
try:
|
||||
converted = d.from_str(text)
|
||||
except configexc.ValidationError:
|
||||
pass
|
||||
else:
|
||||
expected = '' if not val else text
|
||||
assert d.to_str(converted) == expected
|
||||
return
|
||||
|
||||
if len(converted) > 1:
|
||||
# For longer dicts, the key order could be switched
|
||||
return
|
||||
|
||||
assert d.to_str(converted) == '' if not val else text
|
||||
|
||||
|
||||
def unrequired_class(**kwargs):
|
||||
|
Loading…
Reference in New Issue
Block a user