ignore \r to support test on mac OS and windows