diff options
| author | mike bayer <mike_mp@zzzcomputing.com> | 2023-04-26 20:57:54 +0000 |
|---|---|---|
| committer | Gerrit Code Review <gerrit@bbpush.zzzcomputing.com> | 2023-04-26 20:57:54 +0000 |
| commit | f476155d21f6fb2e8e5cf5d874f7ec149e8205b4 (patch) | |
| tree | b5fdd12298e55edb4968ec08ee7c80186abaf14a /lib/sqlalchemy/testing | |
| parent | 7a5ae20dcea05848ffa82321e31fc83c78621079 (diff) | |
| parent | 188cb4226ac7b337446689ab3498b4397d0b7d2d (diff) | |
| download | sqlalchemy-f476155d21f6fb2e8e5cf5d874f7ec149e8205b4.tar.gz | |
Merge "disable "bytes" handler for all drivers other than psycopg2" into main
Diffstat (limited to 'lib/sqlalchemy/testing')
| -rw-r--r-- | lib/sqlalchemy/testing/suite/test_types.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/sqlalchemy/testing/suite/test_types.py b/lib/sqlalchemy/testing/suite/test_types.py index 3ba7f8e89..72f1e8c10 100644 --- a/lib/sqlalchemy/testing/suite/test_types.py +++ b/lib/sqlalchemy/testing/suite/test_types.py @@ -279,7 +279,6 @@ class ArrayTest(_LiteralRoundTripFixture, fixtures.TablesTest): class BinaryTest(_LiteralRoundTripFixture, fixtures.TablesTest): - __requires__ = ("binary_literals",) __backend__ = True @classmethod @@ -294,14 +293,15 @@ class BinaryTest(_LiteralRoundTripFixture, fixtures.TablesTest): Column("pickle_data", PickleType), ) - def test_binary_roundtrip(self, connection): + @testing.combinations(b"this is binary", b"7\xe7\x9f", argnames="data") + def test_binary_roundtrip(self, connection, data): binary_table = self.tables.binary_table connection.execute( - binary_table.insert(), {"id": 1, "binary_data": b"this is binary"} + binary_table.insert(), {"id": 1, "binary_data": data} ) row = connection.execute(select(binary_table.c.binary_data)).first() - eq_(row, (b"this is binary",)) + eq_(row, (data,)) def test_pickle_roundtrip(self, connection): binary_table = self.tables.binary_table |
