should also be a test for the last character of the line