def testSuite(self): suite = xunit.TestSuite() suite.add(xunit.WasRun("testMethod")) suite.add(xunit.WasRun("testBrokenMethod")) result = xunit.TestResult() suite.run(result) assert ("2 run, 1 failed" == result.summary())
def testTemplateMethod(self): test = xunit.WasRun("testMethod") test.run(self.result) assert ("setUp testMethod tearDown " == test.log)
def testFailedResult(self): test = xunit.WasRun("testBrokenMethod") test.run(self.result) assert ("1 run, 1 failed" == self.result.summary())
def testResult(self): test = xunit.WasRun("testMethod") test.run(self.result) assert ("1 run, 0 failed" == self.result.summary())
def testExceptionThrownInSetUp(self): test = xunit.WasRun()
def testTearDown(self): test = xunit.WasRun("testBrokenMethod") test.run(self.result) assert ("setUp tearDown " == test.log)