Write test for longest word method