Example #1
0
 def testCollectInfoYesNo(self):
    self.infoCollector = InfoCollector(self.classesToCollectInfoAbout)
    self.timesGlobalTraceWasCalled = 0
    self.infoCollector.globalTrace = self.mockGlobalTrace
    self.infoCollector.collectInfoYes()
    testClassOne = TestClassOne()
    testClassOne.methodOne()
    self.infoCollector.collectInfoNo()
    testClassOne.methodOne()
    self.assertEqual(3, self.timesGlobalTraceWasCalled)
Example #2
0
 def excerciseTestClasses(self):
    testClassOne = TestClassOne()
    testClassOne.methodOne("foo")
    testClassOne.methodTwo(1111, "bar")
    testClassTwo = TestClassTwo()
    testClassTwo.methodOne()
    testClassTwo.methodTwo()
    testClassThree = TestClassThree()
    testClassThree.privateMethod()
    testClassThree.publicMethod()
    testClassFour = TestClassFour()
    testClassFour.methodOne("a", 1, 3.14592)
Example #3
0
 def testCollectInfoYesNo(self):
     self.infoCollector = InfoCollector(self.classesToCollectInfoAbout)
     self.timesGlobalTraceWasCalled = 0
     self.infoCollector.globalTrace = self.mockGlobalTrace
     self.infoCollector.collectInfoYes()
     testClassOne = TestClassOne()
     testClassOne.methodOne()
     self.infoCollector.collectInfoNo()
     testClassOne.methodOne()
     self.assertEqual(3, self.timesGlobalTraceWasCalled)
Example #4
0
 def excerciseTestClasses(self):
     testClassOne = TestClassOne()
     testClassOne.methodOne("foo")
     testClassOne.methodTwo(1111, "bar")
     testClassTwo = TestClassTwo()
     testClassTwo.methodOne()
     testClassTwo.methodTwo()
     testClassThree = TestClassThree()
     testClassThree.privateMethod()
     testClassThree.publicMethod()
     testClassFour = TestClassFour()
     testClassFour.methodOne("a", 1, 3.14592)