def testOverdraw(self): tis = TimeInSeconds("88") assert tis.subtractSeconds(100) == -12 assert tis.inSeconds() == "0"
def testInitInMinutesAndSeconds(self): tis = TimeInSeconds("3:25") assert tis.inSeconds() == "205" assert tis.inMinutesAndSeconds() == "3:25"
def testSubtractSeconds(self): tis = TimeInSeconds("99") assert tis.subtractSeconds(50) == 49 assert tis.inSeconds() == "49"
def testInitInSeconds(self): tis = TimeInSeconds("59") assert tis.inSeconds() == "59" assert tis.inMinutesAndSeconds() == "0:59"