From 14196b6ce16fecf5a2071b92aaaaa03d7f44adb3 Mon Sep 17 00:00:00 2001 From: Diogo Baeder de Paula Pinto Date: Tue, 26 Mar 2019 03:41:14 -0300 Subject: [PATCH] Fix #124: Fixing test for Python 2. --- tests/unit/schema/test_schemas.py | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/tests/unit/schema/test_schemas.py b/tests/unit/schema/test_schemas.py index 50c92c9..9fc7ed0 100644 --- a/tests/unit/schema/test_schemas.py +++ b/tests/unit/schema/test_schemas.py @@ -713,11 +713,11 @@ class TestSchemaValidate(object): @pytest.mark.parametrize('value', [ Model({ - 'foo': 'FOO', + u'foo': u'FOO', }), Model({ - 'foo': 'FOO', - 'bar': 'BAR', + u'foo': u'FOO', + u'bar': u'BAR', }), ]) def test_unambiguous_one_of(self, value): @@ -725,17 +725,19 @@ class TestSchemaValidate(object): Schema( 'object', properties={ - 'bar': Schema('string'), + u'foo': Schema('string'), }, additional_properties=False, + required=[u'foo'], ), Schema( 'object', properties={ - 'foo': Schema('string'), - 'bar': Schema('string'), + u'foo': Schema('string'), + u'bar': Schema('string'), }, additional_properties=False, + required=[u'foo', u'bar'], ), ] schema = Schema('object', one_of=one_of)