UNITTEST problem!!! :(

andrea frosoni andrea.frosoni at mclink.it
Tue Feb 11 22:08:23 CET 2003

the code listed down is correct???
don't work right

Help me

def testFunc1(self):
        "Test func1"
        # call func1
        ret = self.pingObj.func1(
            host = '',		#sample host for ping
            num = '10')				#number of packets sent
        self.assertEqual(ret, 10, "ping.func1 did not work")#10 
number of 						#packet shoud be return#

    def testFunc2(self):
        "Test func2"
        # call func2
        ret = self.pingObj.func2()
        self.failUnless(ret, "ping.func2 did not work")

More information about the Python-list mailing list