tests/run-tests.py
branchstable
changeset 48273 3a95a4e660b9
parent 47834 d3f890e04525
child 48277 96aa3a68d3b5
equal deleted inserted replaced
48272:f6b045910d82 48273:3a95a4e660b9
  2231 
  2231 
  2232 iolock = threading.RLock()
  2232 iolock = threading.RLock()
  2233 firstlock = threading.RLock()
  2233 firstlock = threading.RLock()
  2234 firsterror = False
  2234 firsterror = False
  2235 
  2235 
  2236 
  2236 if PYTHON3:
  2237 class TestResult(unittest._TextTestResult):
  2237     base_class = unittest.TextTestResult
       
  2238 else:
       
  2239     base_class = unittest._TextTestResult
       
  2240 
       
  2241 
       
  2242 class TestResult(base_class):
  2238     """Holds results when executing via unittest."""
  2243     """Holds results when executing via unittest."""
  2239 
  2244 
  2240     # Don't worry too much about accessing the non-public _TextTestResult.
       
  2241     # It is relatively common in Python testing tools.
       
  2242     def __init__(self, options, *args, **kwargs):
  2245     def __init__(self, options, *args, **kwargs):
  2243         super(TestResult, self).__init__(*args, **kwargs)
  2246         super(TestResult, self).__init__(*args, **kwargs)
  2244 
  2247 
  2245         self._options = options
  2248         self._options = options
  2246 
  2249