| Issue 3: | Tests fail on case-sensitive file system + system dependent directory separator | |
| 2 people starred this issue and may be notified of changes. | Back to list |
What steps will reproduce the problem?
1.Use case-sensitive file system
2.Try to build jar with maven
What is the expected output? What do you see instead?
All tests fail on a case-sensitive file system
with a file-not-found exception
What version of the product are you using? On what operating system?
Current version. An Ubuntu based distro.
Please provide any additional information below.
Solution:
The default file system is case-sensitive, in the code all all files have a lowercase extension (.dds), some of the test files have an uppercase extension. (.DDS)
(in src/test/resources/net/nikr/dds/)
For example ATI1N.DDS should be ATI1N.dds
Rename all .DDS files to .dds to solve this issue
The only other problem are the system-specific directory separators.
Windows uses a backslash, the rest a forward slash.
Use the constant "File.separator" for directory separators to avoid this problem:
in DDSImageReaderTest.java
...
private class TestParams{
private final String pathSeparator = File.separator;
private final String dir = "src" + pathSeparator + "test" + pathSeparator + "resources" + pathSeparator + "net" + pathSeparator + "nikr" + pathSeparator + "dds" + pathSeparator;
...
After those corrections the project compiled
Nov 28, 2013
#1
the0xF...@gmail.com
Nov 29, 2013
Thank you for your bug reports. Completed in r20 If you could validate that it works now and reply here, that would be very much appreciated.
Owner:
nikla...@gmail.com
Nov 29, 2013
Fixed some more File.separator in r21 (that should be all of them)
Dec 1, 2013
Tests are running through
Dec 2, 2013
(No comment was entered for this change.)
Status:
Fixed
|