[py-svn] r36897 - py/branch/conftest/py/test

hpk at codespeak.net hpk at codespeak.net
Thu Jan 18 06:30:39 CET 2007


Author: hpk
Date: Thu Jan 18 06:30:38 2007
New Revision: 36897

Modified:
   py/branch/conftest/py/test/collect.py
   py/branch/conftest/py/test/config.py
Log:
small option cleanup: have --usepdb imply --nocapture directly


Modified: py/branch/conftest/py/test/collect.py
==============================================================================
--- py/branch/conftest/py/test/collect.py	(original)
+++ py/branch/conftest/py/test/collect.py	Thu Jan 18 06:30:38 2007
@@ -391,7 +391,7 @@
         return res
     
     def startcapture(self): 
-        if not self.option.nocapture and not self.option.usepdb: 
+        if not self.option.nocapture:
             assert not hasattr(self, '_capture')
             #self._capture = py.io.OutErrCapture() 
             # XXX integrate this into py.io / refactor

Modified: py/branch/conftest/py/test/config.py
==============================================================================
--- py/branch/conftest/py/test/config.py	(original)
+++ py/branch/conftest/py/test/config.py	Thu Jan 18 06:30:38 2007
@@ -122,6 +122,11 @@
     else: 
         option.executable = py.std.sys.executable 
 
+    if option.usepdb:
+        if not option.nocapture:
+            print "--usepdb currently implies --nocapture"
+            option.nocapture = True
+
     # make information available about wether we should/will be remote 
     option._remote = remote or option.looponfailing
     option._fromremote = False 



More information about the pytest-commit mailing list