Class SimpleAggregatorTst
- java.lang.Object
-
- net.sourceforge.pmd.testframework.RuleTst
-
- net.sourceforge.pmd.testframework.SimpleAggregatorTst
-
public abstract class SimpleAggregatorTst extends RuleTst
Simple setup for a rule unit test, capable of testing multiple rules.Override
setUp()to register the rules, that should be tested via calls toaddRule(String, String).
-
-
Constructor Summary
Constructors Constructor Description SimpleAggregatorTst()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidaddRule(java.lang.String ruleSet, java.lang.String ruleName)Add new XML tests associated with the rule to the test suite.protected java.util.List<net.sourceforge.pmd.Rule>getRules()Gets all configured rules.protected voidsetUp()Configure the rule tests to be executed.-
Methods inherited from class net.sourceforge.pmd.testframework.RuleTst
extractTestsFromXml, extractTestsFromXml, extractTestsFromXml, findRule, getCleanRuleName, reinitializeRule, runTest, runTestFromString, runTestFromString, runTestFromString, runTests, runTests, runTests
-
-
-
-
Method Detail
-
setUp
protected void setUp()
Configure the rule tests to be executed. Override this method in subclasses by calling addRule, e.g.addRule("path/myruleset.xml", "CustomRule");- Overrides:
setUpin classRuleTst- See Also:
addRule(String, String)
-
addRule
protected void addRule(java.lang.String ruleSet, java.lang.String ruleName)Add new XML tests associated with the rule to the test suite. This should be called from the setup method.
-
-