Exemplo n.º 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)
Exemplo n.º 2
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)
Exemplo n.º 3
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)
Exemplo n.º 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)