From eaa2f47bb1bb7ad6a9bc1ae1b8703e1f8fa9d0e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89loi=20Rivard?= Date: Sat, 6 Nov 2021 10:01:22 +0100 Subject: [PATCH 1/2] sqla_types.Binary is no more used --- tests/tests.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/tests/tests.py b/tests/tests.py index 1b6e54b..4654473 100755 --- a/tests/tests.py +++ b/tests/tests.py @@ -25,9 +25,9 @@ from wtforms import Form from wtforms.compat import iteritems from wtforms.compat import text_type +from wtforms.validators import InputRequired from wtforms.validators import Optional from wtforms.validators import Regexp -from wtforms.validators import InputRequired from .common import contains_validator from .common import DummyPostData @@ -439,7 +439,6 @@ class AllTypesModel(Model): numeric = Column(sqla_types.Numeric) float = Column(sqla_types.Float) text = Column(sqla_types.Text) - binary = Column(sqla_types.Binary) largebinary = Column(sqla_types.LargeBinary) unicodetext = Column(sqla_types.UnicodeText) enum = Column(sqla_types.Enum("Primary", "Secondary")) @@ -474,7 +473,6 @@ def test_convert_types(self): assert isinstance(form.float, fields.DecimalField) assert isinstance(form.text, fields.TextAreaField) - assert isinstance(form.binary, fields.TextAreaField) assert isinstance(form.largebinary, fields.TextAreaField) assert isinstance(form.unicodetext, fields.TextAreaField) From b5c7fe8cc45a0a35c97400202e4e60ce89657f96 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89loi=20Rivard?= Date: Sat, 6 Nov 2021 10:40:57 +0100 Subject: [PATCH 2/2] mapper has no order_by argument anymore --- tests/tests.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/tests.py b/tests/tests.py index 4654473..0fbba37 100755 --- a/tests/tests.py +++ b/tests/tests.py @@ -76,8 +76,8 @@ def _do_tables(self, mapper, engine): {"__unicode__": lambda x: x.baz, "__str__": lambda x: x.baz}, ) - mapper(Test, test_table, order_by=[test_table.c.name]) - mapper(PKTest, pk_test_table, order_by=[pk_test_table.c.baz]) + mapper(Test, test_table) + mapper(PKTest, pk_test_table) self.Test = Test self.PKTest = PKTest