def test_hello(self): friend_name = "Pepe" assert hello(friend_name) == "Hello, %s!" % friend_name
def test_hello(self): self.assertTrue("Hello" in hello("Bob"))
def test_hello_no_arg(self): self.assertTrue("Hello" in hello())
def test_hello(self): self.assertEqual(hello('Mihai'), 'Hello, Mihai!')
def test_hello_outputs_correct_name(self): result = hello('John') self.assertEqual('Hello, John!', result)
def test_hello(self): self.assertEqual(hello("John"), "Hello, John!") self.assertEqual(hello(""), "Hello, !")
def test_hello_return_type(self): self.assertTrue(isinstance(hello("world"), str))
def test_hello(friend, expected): h = hello(friend) assert h == "Hello, {}!".format(expected)