Skip to content

Commit f4e42c5

Browse files
authored
replace ensure_clean with temp_file in pandas/tests/io/sas/test_sas.py
replace ensure_clean with temp_file in pandas/tests/io/sas/test_sas.py
1 parent 54c26ec commit f4e42c5

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

pandas/tests/io/sas/test_sas.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,12 @@ def test_sas_buffer_format(self):
1818
with pytest.raises(ValueError, match=msg):
1919
read_sas(b)
2020

21-
def test_sas_read_no_format_or_extension(self):
21+
def test_sas_read_no_format_or_extension(self, temp_file):
2222
# see gh-24548
2323
msg = "unable to infer format of SAS file.+"
24-
with tm.ensure_clean("test_file_no_extension") as path:
25-
with pytest.raises(ValueError, match=msg):
26-
read_sas(path)
24+
# Using the pytest temp_file fixture instead of tm.ensure_clean
25+
with pytest.raises(ValueError, match=msg):
26+
read_sas(temp_file)
2727

2828

2929
def test_sas_archive(datapath):

0 commit comments

Comments
 (0)