}
@Test
public void validateRepository_notok() throws Exception {
File root = TestDataProvider.getTestFile(new Path("testData/forgeModules/lab42-activemq-0.1.2-withErrors/"));
ValidationService vs = getValidationService();
Diagnostic chain = new Diagnostic();
// Set options like API1 would behave for a validateRepository
ValidationOptions options = getValidationOptions();
options.setCheckLayout(true);
options.setCheckModuleSemantics(false);
options.setCheckReferences(false);
options.setFileType(FileType.PUPPET_ROOT);
vs.validate(chain, root, options, null, SubMonitor.convert(null));
assertNotEquals("There should be errors", 0, chain.getChildren().size());
Set<String> fileNames = Sets.newHashSet();
for(Diagnostic d : chain) {
if("This is not a boolean".equals(d.getMessage()))
continue; // skip this error (UGLY)