浏览代码

Capture stderr messages when running tests

Mike Naberezny 12 年之前
父节点
当前提交
5775749256
共有 1 个文件被更改,包括 4 次插入0 次删除
  1. 4 0
      supervisor/tests/test_options.py

+ 4 - 0
supervisor/tests/test_options.py

@@ -186,6 +186,8 @@ class ClientOptionsTests(unittest.TestCase):
         self.assertFalse(os.path.exists(fname))
 
         instance = self._makeOne()
+        instance.stderr = StringIO()
+
         class DummyException(Exception):
             def __init__(self, exitcode):
                 self.exitcode = exitcode
@@ -591,6 +593,8 @@ class ServerOptionsTests(unittest.TestCase):
         self.assertFalse(os.path.exists(fname))
 
         instance = self._makeOne()
+        instance.stderr = StringIO()
+
         class DummyException(Exception):
             def __init__(self, exitcode):
                 self.exitcode = exitcode