@Test
public void testCopyScriptsInTargetDirectory() throws IOException {

	File f = new File( this.folder.newFolder(), "toto.properties" );
	Assert.assertTrue( new File( f.getParentFile(), "toto" ).mkdir());
	Utils.writeStringInto( "id: tid\nprop: value\nhandler: h", f );
	Utils.writeStringInto( "#!/bin/bash\necho Bonjour le monde cruel > toto.txt", new File( f.getParentFile(), "toto/toto.sh" ));
	Utils.writeStringInto( "#!/bin/bash\ntouch titi.txt", new File( f.getParentFile(), "titi.sh" ));
	Utils.writeStringInto( "#!/bin/bash\necho tototo", new File( f.getParentFile(), "toto/script.sh" ));
	File targetDir = new File( this.configurationMngr.getWorkingDirectory(), ConfigurationUtils.TARGETS + "/tid" );
	Assert.assertFalse( targetDir.exists());
	TestApplicationTemplate appT = new TestApplicationTemplate();
	String targetId = this.mngr.createTarget( f, appT );
	Assert.assertEquals( "tid", targetId );
	Assert.assertTrue( targetDir.exists());
	Assert.assertEquals( 3, targetDir.list().length);
	Assert.assertTrue( new File( targetDir, "target.properties" ).exists());
	Assert.assertTrue( new File( targetDir, "created.from" ).exists());
	Assert.assertTrue( new File( targetDir, Constants.PROJECT_SUB_DIR_SCRIPTS ).isDirectory());
	targetDir = new File( targetDir, Constants.PROJECT_SUB_DIR_SCRIPTS );
	Assert.assertEquals( 2, targetDir.list().length);
	Assert.assertTrue( new File( targetDir, "toto.sh" ).exists());
	Assert.assertTrue( new File( targetDir, "script.sh" ).exists());
	Assert.assertFalse( new File( targetDir, "titi.sh").exists());
}