##// END OF EJS Templates
don't use private TestCase._exc_info() method in parametric test...
MinRK -
Show More
@@ -12,6 +12,7 b''
12 # Imports
12 # Imports
13 #-----------------------------------------------------------------------------
13 #-----------------------------------------------------------------------------
14
14
15 import sys
15 import unittest
16 import unittest
16 from compiler.consts import CO_GENERATOR
17 from compiler.consts import CO_GENERATOR
17
18
@@ -45,7 +46,7 b' class ParametricTestCase(unittest.TestCase):'
45 except KeyboardInterrupt:
46 except KeyboardInterrupt:
46 raise
47 raise
47 except:
48 except:
48 result.addError(self, self._exc_info())
49 result.addError(self, sys.exc_info())
49 return
50 return
50 # Test execution
51 # Test execution
51 ok = False
52 ok = False
@@ -56,18 +57,18 b' class ParametricTestCase(unittest.TestCase):'
56 # We stop the loop
57 # We stop the loop
57 break
58 break
58 except self.failureException:
59 except self.failureException:
59 result.addFailure(self, self._exc_info())
60 result.addFailure(self, sys.exc_info())
60 except KeyboardInterrupt:
61 except KeyboardInterrupt:
61 raise
62 raise
62 except:
63 except:
63 result.addError(self, self._exc_info())
64 result.addError(self, sys.exc_info())
64 # TearDown
65 # TearDown
65 try:
66 try:
66 self.tearDown()
67 self.tearDown()
67 except KeyboardInterrupt:
68 except KeyboardInterrupt:
68 raise
69 raise
69 except:
70 except:
70 result.addError(self, self._exc_info())
71 result.addError(self, sys.exc_info())
71 ok = False
72 ok = False
72 if ok: result.addSuccess(self)
73 if ok: result.addSuccess(self)
73
74
General Comments 0
You need to be logged in to leave comments. Login now