Skip to content

Commit 02514e0

Browse files
fix logic
1 parent f8ae285 commit 02514e0

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

pandas/tests/io/test_sql.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4372,14 +4372,14 @@ def test_bytes_column(con, request):
43724372
df = pd.read_sql(query, conn, dtype_backend=dtype_backend)
43734373

43744374
dtype = "O"
4375-
if dtype_backend == "pyarrow":
4376-
# sqlite3 + mysql both return a binary type
4377-
# for the binary literal
4378-
dtype = pd.ArrowDtype(pa.binary())
4379-
elif dtype_backend == "pyarrow" and "postgres" in con:
4375+
if dtype_backend == "pyarrow" and "postgres" in con:
43804376
# postgres column is a bit type
43814377
# but converts to a string when returned
43824378
dtype = pd.ArrowDtype(pa.string())
4379+
elif dtype_backend == "pyarrow":
4380+
# sqlite3 + mysql both return a binary type
4381+
# for the binary literal
4382+
dtype = pd.ArrowDtype(pa.binary())
43834383

43844384
expected = DataFrame(
43854385
[

0 commit comments

Comments
 (0)