now that we know get_formatted_name(works for simple names againlet' write second test for people who include middle name we do this by adding another method to the class namestestcaseimport unittest from name_function import get_formatted_name class namestestcase(unittest testcase)"""tests for 'name_function py""def test_first_last_name(self)"""do names like 'janis joplinwork?""formatted_name get_formatted_name('janis''joplin'self assertequal(formatted_name'janis joplin'def test_first_last_middle_name(self)"""do names like 'wolfgang amadeus mozartwork?""formatted_name get_formatted_name'wolfgang''mozart''amadeus'self assertequal(formatted_name'wolfgang amadeus mozart' unittest main(we name this new method test_first_last_middle_name(the method name must start with test_ so the method runs automatically when we run test_name_function py we name the method to make it clear which behavior of get_formatted_name(we're testing as resultif the test failswe know right away what kinds of names are affected it' fine to have long method names in your testcase classes they need to be descriptive so you can make sense of the output when your tests failand because python calls them automaticallyyou'll never have to write code that calls these methods to test the functionwe call get_formatted_name(with firstlastand middle name uand then we use assertequal(to check that the returned full name matches the full name (firstmiddleand lastthat we expect when we run test_name_function py againboth tests passran tests in ok greatwe now know that the function still works for names like janis joplinand we can be confident that it will work for names like wolfgang amadeus mozart as well testing your code