def test_do_plus(self): ex_5.do_plus(3,8) self.assertEqual(0, ex_5.do_plus(0, 0), "do_plus() returns wrong result") self.assertEqual(11, ex_5.do_plus(3,8), "do_plus() returns wrong result") self.assertEqual(11, ex_5.do_plus(8,3), "do_plus() returns wrong result") pass
def testEx5_1_correct(self): self.assertEqual(ex_5.do_plus(1, 1), 2, "do_plus returned something wrong") self.assertEqual(ex_5.do_plus(-6, 5), -1, "do_plus returned something wrong") self.assertEqual(ex_5.do_plus(1, 1), 2, "do_plus returned something wrong") self.assertEqual(ex_5.do_plus(1, 1), 2, "do_plus returned something wrong") pass
def test_do_plus(self): ex_5.do_plus(3, 8) self.assertEqual(0, ex_5.do_plus(0, 0), "do_plus() returns wrong result") self.assertEqual(11, ex_5.do_plus(3, 8), "do_plus() returns wrong result") self.assertEqual(11, ex_5.do_plus(8, 3), "do_plus() returns wrong result") pass
def testdo_plus(self): self.assertEqual(13, ex_5.do_plus(5, 8), "do_plus() returned a wrong result") self.assertEqual(23, ex_5.do_plus(11, 12), "do_plus() returned a wrong result") self.assertEqual(2, ex_5.do_plus(10, 2), "do_plus() returned a wrong result") pass
def test_do_plus_mixed(self): self.assertEqual("hi5", ex_5.do_plus("hi", 5), "Could not add a text to an int")
def test_do_plus_strings(self): self.assertEqual("Hi There", ex_5.do_plus("Hi", "There"), "do__plus() returns wrong result")
def test_do_plus(self): self.assertEqual(5, ex_5.do_plus(2, 3), "do_plus() returned a wrong result")
def testEx5_1_correct(self): self.assertEqual(ex_5.do_plus(1,1), 2, "do_plus returned something wrong") self.assertEqual(ex_5.do_plus(-6,5), -1, "do_plus returned something wrong") self.assertEqual(ex_5.do_plus(1,1), 2, "do_plus returned something wrong") self.assertEqual(ex_5.do_plus(1,1), 2, "do_plus returned something wrong") pass