[Python-checkins] r85984 - python/branches/py3k/Lib/test/test_pkgimport.py

brian.curtin python-checkins at python.org
Sat Oct 30 23:03:18 CEST 2010


Author: brian.curtin
Date: Sat Oct 30 23:03:18 2010
New Revision: 85984

Log:
Fix #10256 - resource warning


Modified:
   python/branches/py3k/Lib/test/test_pkgimport.py

Modified: python/branches/py3k/Lib/test/test_pkgimport.py
==============================================================================
--- python/branches/py3k/Lib/test/test_pkgimport.py	(original)
+++ python/branches/py3k/Lib/test/test_pkgimport.py	Sat Oct 30 23:03:18 2010
@@ -29,7 +29,7 @@
         self.package_dir = os.path.join(self.test_dir,
                                         self.package_name)
         os.mkdir(self.package_dir)
-        open(os.path.join(self.package_dir, '__init__.py'), 'w')
+        open(os.path.join(self.package_dir, '__init__.py'), 'w').close()
         self.module_path = os.path.join(self.package_dir, 'foo.py')
 
     def tearDown(self):


More information about the Python-checkins mailing list