Fix #124: Fixing test for Python 2.

This commit is contained in:
Diogo Baeder de Paula Pinto 2019-03-26 03:41:14 -03:00
parent b029066add
commit 14196b6ce1

View file

@ -713,11 +713,11 @@ class TestSchemaValidate(object):
@pytest.mark.parametrize('value', [ @pytest.mark.parametrize('value', [
Model({ Model({
'foo': 'FOO', u'foo': u'FOO',
}), }),
Model({ Model({
'foo': 'FOO', u'foo': u'FOO',
'bar': 'BAR', u'bar': u'BAR',
}), }),
]) ])
def test_unambiguous_one_of(self, value): def test_unambiguous_one_of(self, value):
@ -725,17 +725,19 @@ class TestSchemaValidate(object):
Schema( Schema(
'object', 'object',
properties={ properties={
'bar': Schema('string'), u'foo': Schema('string'),
}, },
additional_properties=False, additional_properties=False,
required=[u'foo'],
), ),
Schema( Schema(
'object', 'object',
properties={ properties={
'foo': Schema('string'), u'foo': Schema('string'),
'bar': Schema('string'), u'bar': Schema('string'),
}, },
additional_properties=False, additional_properties=False,
required=[u'foo', u'bar'],
), ),
] ]
schema = Schema('object', one_of=one_of) schema = Schema('object', one_of=one_of)