mirror of
https://github.com/python/cpython.git
synced 2025-08-22 17:55:18 +00:00
Merged revisions 86223-86224,86226,86234 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r86223 | eric.araujo | 2010-11-06 00:51:56 +0100 (sam., 06 nov. 2010) | 2 lines Always close files in distutils code and tests (#10252). ........ r86224 | eric.araujo | 2010-11-06 00:58:34 +0100 (sam., 06 nov. 2010) | 2 lines Add missing entry for r86223. ........ r86226 | eric.araujo | 2010-11-06 00:59:32 +0100 (sam., 06 nov. 2010) | 2 lines Of course, I forgot one file in r86223. ........ r86234 | eric.araujo | 2010-11-06 03:10:32 +0100 (sam., 06 nov. 2010) | 2 lines Also close file descriptors from os.popen and subprocess.Popen ........
This commit is contained in:
parent
860c05d9f7
commit
d1feff70a3
27 changed files with 297 additions and 194 deletions
|
@ -42,8 +42,10 @@ class InstallScriptsTestCase(support.TempdirManager,
|
|||
def write_script(name, text):
|
||||
expected.append(name)
|
||||
f = open(os.path.join(source, name), "w")
|
||||
f.write(text)
|
||||
f.close()
|
||||
try:
|
||||
f.write(text)
|
||||
finally:
|
||||
f.close()
|
||||
|
||||
write_script("script1.py", ("#! /usr/bin/env python2.3\n"
|
||||
"# bogus script w/ Python sh-bang\n"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue