Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
2.1.1
-
None
-
Patch
Description
FreeMarkerResultTest.testWithoutWriteIfCompleted fails when the build is run from a path which contains spaces.
The reason for this is that the following line code exists in the setUp method of FreeMarkerResultTest;
servletContext.setRealPath(FreeMarkerResultTest.class.getResource("someFreeMarkerFile.ftl").getFile());
getResource returns a URL, which means that any spaces are converted into %20, and thus instead of the real path being set as "a b" it gets set as "a%20b" and thus all paths are ".../a%20b/..." instead of ".../a b/..." causing the file to fail to open.