Class 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 to addRule(String, String).

    • Constructor Detail

      • SimpleAggregatorTst

        public SimpleAggregatorTst()
    • 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:
        setUp in class RuleTst
        See Also:
        addRule(String, String)
      • addRule

        protected void addRule​(String ruleSet,
                               String ruleName)
        Add new XML tests associated with the rule to the test suite. This should be called from the setup method.
      • getRules

        protected List<Rule> getRules()
        Gets all configured rules.
        Overrides:
        getRules in class RuleTst
        Returns:
        all configured rules.