@Test
public void copyIfExists() throws IOException {
final Path target = util.createTempDir().toPath();
assertThat(DirSupport.copyIfExists(root.toPath().resolve("not-existing"), target), is(false));
assertThat(DirSupport.copyIfExists(root.toPath(), target), is(true));
assertThat(target.toFile(), exists());
assertThat(target.toFile(), isDirectory());
assertThat(target.toFile(), not(isEmptyDirectory()));
assertThat(target.resolve("dir2").resolve("dir21").toFile(), isDirectory());
assertThat(target.resolve("dir2").resolve("dir21").resolve("file211.txt").toFile(), isFile());
}