Skip to content

Commit 323f4ea

Browse files
committed
TST: Replace ensure_clean with temp_file fixture in test_xml.py iterparse tests
1 parent 5cc3240 commit 323f4ea

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

pandas/tests/io/xml/test_xml.py

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -263,11 +263,10 @@ def parser(request):
263263
return request.param
264264

265265

266-
def read_xml_iterparse(data, **kwargs):
267-
with tm.ensure_clean() as path:
268-
with open(path, "w", encoding="utf-8") as f:
269-
f.write(data)
270-
return read_xml(path, **kwargs)
266+
def read_xml_iterparse(data, temp_file, **kwargs):
267+
with open(temp_file, "w", encoding="utf-8") as f:
268+
f.write(data)
269+
return read_xml(temp_file, **kwargs)
271270

272271

273272
def read_xml_iterparse_comp(comp_path, compression_only, **kwargs):

0 commit comments

Comments
 (0)