sourceDirectory.createData("test.php");
// existing directory
YiiCustomizerValidator validator = new YiiCustomizerValidator()
.validateDirectory(sourceDirectory, "myfolder");
ValidationResult result = validator.getResult();
assertFalse(result.hasErrors());
assertFalse(result.hasWarnings());
// not existing directory
validator = new YiiCustomizerValidator()
.validateDirectory(sourceDirectory, "dummy");
result = validator.getResult();
assertFalse(result.hasErrors());
assertTrue(result.hasWarnings());
// file
validator = new YiiCustomizerValidator()
.validateDirectory(sourceDirectory, "test.php");
result = validator.getResult();
assertFalse(result.hasErrors());
assertTrue(result.hasWarnings());
}