@@ -750,8 +750,7 @@ def postgresql_psycopg2_conn_types(postgresql_psycopg2_engine_types):
750
750
@pytest .fixture
751
751
def sqlite_str (temp_file ):
752
752
pytest .importorskip ("sqlalchemy" )
753
- name = str (temp_file )
754
- return f"sqlite:///{ name } "
753
+ return f"sqlite:///{ temp_file } "
755
754
756
755
757
756
@pytest .fixture
@@ -822,8 +821,7 @@ def sqlite_adbc_conn(temp_file):
822
821
pytest .importorskip ("adbc_driver_sqlite" )
823
822
from adbc_driver_sqlite import dbapi
824
823
825
- name = str (temp_file )
826
- uri = f"file:{ name } "
824
+ uri = f"file:{ temp_file } "
827
825
with dbapi .connect (uri ) as conn :
828
826
yield conn
829
827
for view in get_all_views (conn ):
@@ -2585,11 +2583,10 @@ def test_sql_open_close(temp_file, test_frame3):
2585
2583
# Test if the IO in the database still work if the connection closed
2586
2584
# between the writing and reading (as in many real situations).
2587
2585
2588
- name = str (temp_file )
2589
- with contextlib .closing (sqlite3 .connect (name )) as conn :
2586
+ with contextlib .closing (sqlite3 .connect (temp_file )) as conn :
2590
2587
assert sql .to_sql (test_frame3 , "test_frame3_legacy" , conn , index = False ) == 4
2591
2588
2592
- with contextlib .closing (sqlite3 .connect (name )) as conn :
2589
+ with contextlib .closing (sqlite3 .connect (temp_file )) as conn :
2593
2590
result = sql .read_sql_query ("SELECT * FROM test_frame3_legacy;" , conn )
2594
2591
2595
2592
tm .assert_frame_equal (test_frame3 , result )
0 commit comments