MCPcopy Index your code
hub / github.com/python/cpython / test_unoverwritable_fails

Method test_unoverwritable_fails

Lib/test/test_venv.py:412–419  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

410 rmtree(fn)
411
412 def test_unoverwritable_fails(self):
413 #create a file clashing with directories in the env dir
414 for paths in self.ENV_SUBDIRS[:3]:
415 fn = os.path.join(self.env_dir, *paths)
416 with open(fn, 'wb') as f:
417 f.write(b'')
418 self.assertRaises((ValueError, OSError), venv.create, self.env_dir)
419 self.clear_directory(self.env_dir)
420
421 def test_upgrade(self):
422 """

Callers

nothing calls this directly

Calls 5

clear_directoryMethod · 0.95
openFunction · 0.50
joinMethod · 0.45
writeMethod · 0.45
assertRaisesMethod · 0.45

Tested by

no test coverage detected