test on ~ at the end of line