Matrix Rules and Decision Table Rules are powerful, but can be a little harder to use than simple If/Then rules. To make things easier, Sliderule has built-in testing while Editing a rule.
Simply click the Test tab from the Editor, and you'll see a variety of Test options to help you confirm your rule is working as expected.
It's easy to make mistakes with less than / greater than logic, or to miss a number from a list. You can use Coverage Testing to spot gaps in how your rule "Covers" the full range of possibilities for a variable. For example, if your input variable can be any integer, are you missing the number 7 from your Matrix rule's list of conditions?
See if you can spot the problem with fico in the sample rule below, and why this Coverage test is throwing a warning.
You can also try out a Test Input and see how your rule would run. You can edit the variables in the left hand input panel, to try out different input options. Notice the Green cell highlights when you click Test - this indicates this particular Action cell of your Rule would be triggered for the Test Input you've included here.
If your Test Input doesn't match any conditions in your rule, you'll see a red message, with the option to show any Partial Matches if possible. This can be helpful if you were expecting a match, and want to see how your Rule is behaving differently than your expectations.
Updated 6 months ago