[Python-checkins] distutils2: Don’t display skip messages for tests that we’ll never fix

eric.araujo python-checkins at python.org
Fri Nov 25 16:23:59 CET 2011


http://hg.python.org/distutils2/rev/1b8f84f165c3
changeset:   1264:1b8f84f165c3
parent:      1262:a382d149a0f0
user:        Éric Araujo <merwok at netwok.org>
date:        Wed Nov 23 13:50:55 2011 +0100
summary:
  Don’t display skip messages for tests that we’ll never fix

files:
  distutils2/_backport/tests/test_shutil.py |  13 +++++-----
  1 files changed, 7 insertions(+), 6 deletions(-)


diff --git a/distutils2/_backport/tests/test_shutil.py b/distutils2/_backport/tests/test_shutil.py
--- a/distutils2/_backport/tests/test_shutil.py
+++ b/distutils2/_backport/tests/test_shutil.py
@@ -917,8 +917,9 @@
 
         self.assertRaises(IOError, shutil.copyfile, 'srcfile', 'destfile')
 
-    @unittest.skip("can't use the with statement and support 2.4")
-    def test_w_dest_open_fails(self):
+    # can't test usage of the with statement and support 2.4, so this
+    # test is renamed to disable it
+    def _test_w_dest_open_fails(self):
 
         srcfile = self.Faux()
 
@@ -937,8 +938,8 @@
         self.assertEqual(srcfile._exited_with[1].args,
                          ('Cannot open "destfile"',))
 
-    @unittest.skip("can't use the with statement and support 2.4")
-    def test_w_dest_close_fails(self):
+    # see above
+    def _test_w_dest_close_fails(self):
 
         srcfile = self.Faux()
         destfile = self.Faux(True)
@@ -960,8 +961,8 @@
         self.assertEqual(srcfile._exited_with[1].args,
                          ('Cannot close',))
 
-    @unittest.skip("can't use the with statement and support 2.4")
-    def test_w_source_close_fails(self):
+    # see above
+    def _test_w_source_close_fails(self):
 
         srcfile = self.Faux(True)
         destfile = self.Faux()

-- 
Repository URL: http://hg.python.org/distutils2


More information about the Python-checkins mailing list