Skip to content

Commit

Permalink
Merge pull request #6344 from Jnction/fix/build_path
Browse files Browse the repository at this point in the history
Fix test failure when building OTP in a path with special characters
  • Loading branch information
tkalvas authored Dec 19, 2024
2 parents ed2d7f5 + b9f4135 commit 4198bb6
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,12 @@ public static ResourceLoader of(Object object) {
*/
public File file(String path) {
URL resource = url(path);
var file = new File(resource.getFile());
File file;
try {
file = new File(new URI(resource.toString()));
} catch (URISyntaxException e) {
throw new RuntimeException(e);
}
assertTrue(
file.exists(),
"File '%s' not found on file system.".formatted(file.getAbsolutePath())
Expand Down

0 comments on commit 4198bb6

Please sign in to comment.