@Test
public void existentToFileTest() throws IOException {

    File originalFile = new File(transformedAppFolder, "src/main/resources/dogs.yaml");
    File toDir = new File(transformedAppFolder, "/src/main/resources/more_yaml/");
    assertTrue(originalFile.exists());
    assertTrue(originalFile.isFile());
    assertTrue(toDir.exists());
    assertTrue(new File(toDir, "dogs.yaml").exists());
    // Saving original file as a temp file to have its content compared later
    File tempOriginalFile = File.createTempFile("butterfly-test-file", null);
    FileUtils.copyFile(originalFile, tempOriginalFile);
    MoveFile moveFile = new MoveFile().relative("src/main/resources/dogs.yaml").setToRelative("src/main/resources/more_yaml");
    TOExecutionResult executionResult = moveFile.execution(transformedAppFolder, transformationContext);
    assertEquals(executionResult.getType(), TOExecutionResult.Type.SUCCESS);
    assertEquals(moveFile.getDescription(), "Move file src/main/resources/dogs.yaml to src/main/resources/more_yaml");
    assertEquals(executionResult.getDetails(), "File 'src/main/resources/dogs.yaml' has been moved to '/src/main/resources/more_yaml'");
    File movedFile = new File(transformedAppFolder, "src/main/resources/more_yaml/dogs.yaml");
    assertFalse(originalFile.exists());
    assertTrue(movedFile.exists());
    assertTrue(FileUtils.contentEquals(tempOriginalFile, movedFile));
    tempOriginalFile.delete();
}