Skip to content

Commit a22e7b9

Browse files
committed
BUG: Modify the test_bool_multiIndex_roundtrip_through_parquet function
1 parent 912dca6 commit a22e7b9

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

pandas/tests/io/test_parquet.py

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1469,15 +1469,14 @@ def test_invalid_dtype_backend(self, engine):
14691469
with pytest.raises(ValueError, match=msg):
14701470
read_parquet(path, dtype_backend="numpy")
14711471

1472-
def test_bool_multiIndex(self, tmp_path, pa):
1472+
def test_bool_multiIndex_roundtrip_through_parquet(self, pa):
14731473
# GH 60508
14741474
df = pd.DataFrame(
14751475
[[1, 2], [4, 5]],
14761476
columns=pd.MultiIndex.from_tuples([(True, 'B'), (False, 'C')]),
14771477
)
1478-
df.to_parquet(
1479-
path=tmp_path,
1480-
engine=pa,
1481-
)
1482-
result = read_parquet(tmp_path, engine=pa)
1478+
with tm.ensure_clean("test.parquet") as path:
1479+
df.to_parquet(f, engine=pa)
1480+
1481+
result = read_parquet(path, engine=pa)
14831482
tm.assert_frame_equal(result, df)

0 commit comments

Comments
 (0)