Make toFile method private for promote URI over String #1544
Fix FileUtils unit test on Windows