Skip to content

Commit b26aa11

Browse files
committed
Re-use temp_home in test_find_config_files_disable
1 parent 1587bbb commit b26aa11

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

distutils/tests/test_dist.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -241,9 +241,8 @@ def test_announce(self):
241241
with pytest.raises(ValueError):
242242
dist.announce(args, kwargs)
243243

244-
def test_find_config_files_disable(self, monkeypatch):
244+
def test_find_config_files_disable(self, temp_home):
245245
# Ticket #1180: Allow user to disable their home config file.
246-
temp_home = self.mkdtemp()
247246
if os.name == 'posix':
248247
user_filename = os.path.join(temp_home, ".pydistutils.cfg")
249248
else:
@@ -252,8 +251,6 @@ def test_find_config_files_disable(self, monkeypatch):
252251
with open(user_filename, 'w') as f:
253252
f.write('[distutils]\n')
254253

255-
monkeypatch.setenv('HOME', temp_home)
256-
257254
d = Distribution()
258255
all_files = d.find_config_files()
259256

0 commit comments

Comments
 (0)