-
Notifications
You must be signed in to change notification settings - Fork 78
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Many tests fail on Windows, apparently due to line ending issues #78
Comments
Hi Nicola, thanks for the issue! I am developing under Mac OS and Linux, and so that error did not occur on my systems. However, thanks to your issue in the last days I:
The new Thanks, Ulrich |
Hi Ulrich,
to
With this change all tests pass for me on both Windows and Linux. |
Hi Nicola, I tested I also thought about switching NEWLINE from If the problem persists on your machine, please let me know. The next step would then be to identify the difference between our machines. If you have other questions regarding the parser, also let me know! Ulrich |
Hi Ulrich, Nicola |
I cloned this project on a PC running Windows 10 and proceded to execute
mvn package
withThe result was:
Looking into the first failure, i.e.
io.proleap.cobol.preprocessor.copy.cobolword.variable.CopyCblWrdTest
I noticed that the expected string contains CR-LF sequences as line endings, while the actual string only LF. This happens because, while preprocessing replaces line endings with the LF character,FileUtils.readFileToString()
does not and on Windows test resources contain Windows line endings.A simple way to make tests pass would be to replace calls to
readFileToString()
with something like:However I wonder if this is the correct approach or if it wouldn't be better to make the preprocessor itself more platform independent. I only just started looking into this project and I don't have a clear idea of how things work.
Would you be interested in a pull request tackling Windows support? I ask because this project appears to have been quiescent for the last year and a half.
The text was updated successfully, but these errors were encountered: