fixing line endings and test cases