Merge branch 'checksum-aware' of https://github.com/Monits/pmd into pr-145

This commit is contained in:
Andreas Dangel
2016-12-23 18:21:50 +01:00
14 changed files with 599 additions and 618 deletions

View File

@@ -218,8 +218,7 @@ public abstract class RuleTst {
ctx.setSourceCodeFilename("n/a");
ctx.setLanguageVersion(languageVersion);
ctx.setIgnoreExceptions(false);
RuleSet rules = new RuleSet();
rules.addRule(rule);
RuleSet rules = new RuleSetFactory().createSingleRuleRuleSet(rule);
rules.start(ctx);
p.getSourceCodeProcessor().processSourceCode(new StringReader(code), new RuleSets(rules), ctx);
rules.end(ctx);

View File

@@ -43,7 +43,8 @@ public class RuleTstTest {
verify(rule).getMinimumLanguageVersion();
verify(rule).getMaximumLanguageVersion();
verify(rule).apply(anyList(), any(RuleContext.class));
verify(rule).getName();
verify(rule, times(2)).getName();
verify(rule).getPropertiesByPropertyDescriptor();
verifyNoMoreInteractions(rule);
}
}