File (@NotNull String target, @NotNull String junction) { assertTrue(SystemInfo.isWindows); File targetFile = new File(target); assertTrue(targetFile.getPath(), targetFile.isDirectory()); File junctionFile = getFullLinkPath(junction); runCommand("cmd", "/C", "mklink", "/J", junctionFile.getPath(), targetFile.getPath()); assertTrue("target=" + targetFile + ", link=" + junctionFile, junctionFile.isDirectory()); return junctionFile; }