[Python-checkins] r57717 - python/trunk/Lib/test/test_pipes.py python/trunk/Lib/test/test_winreg.py

georg.brandl python-checkins at python.org
Thu Aug 30 14:32:23 CEST 2007


Author: georg.brandl
Date: Thu Aug 30 14:32:23 2007
New Revision: 57717
Modified:
 python/trunk/Lib/test/test_pipes.py
 python/trunk/Lib/test/test_winreg.py
Log:
* Skip test_pipes on non-POSIX.
* Don't raise TestSkipped within a test function.
Modified: python/trunk/Lib/test/test_pipes.py
==============================================================================
--- python/trunk/Lib/test/test_pipes.py	(original)
+++ python/trunk/Lib/test/test_pipes.py	Thu Aug 30 14:32:23 2007
@@ -2,7 +2,10 @@
 import os
 import string
 import unittest
-from test.test_support import TESTFN, run_unittest, unlink
+from test.test_support import TESTFN, run_unittest, unlink, TestSkipped
+
+if os.name != 'posix':
+ raise TestSkipped('pipes module only works on posix')
 
 TESTFN2 = TESTFN + "2"
 
Modified: python/trunk/Lib/test/test_winreg.py
==============================================================================
--- python/trunk/Lib/test/test_winreg.py	(original)
+++ python/trunk/Lib/test/test_winreg.py	Thu Aug 30 14:32:23 2007
@@ -157,8 +157,7 @@
 
 def testRemoteMachineRegistryWorks(self):
 if not self.remote_name:
- raise test_support.TestSkipped("Remote machine name "
- "not specified.")
+ return # remote machine name not specified
 remote_key = ConnectRegistry(self.remote_name, HKEY_CURRENT_USER)
 self.TestAll(remote_key)
 


More information about the Python-checkins mailing list

AltStyle によって変換されたページ (->オリジナル) /