Add test for trailing whitespace

Changed and rebased! :smiley: