View all services
Talk to QA Advisor
Free tool · Test design

Decision table testing, generated

When a business rule depends on several conditions at once, the combinations multiply faster than anyone can keep in their head. List the conditions and actions, mark what should happen in each case, and get the complete table and its reduced form.

Runs entirely in your browser. Nothing you enter is sent to a server.

List what the rule depends on and what it can do. You get every combination, decide what should happen in each, and the tool reduces it to the fewest tests that still cover every outcome.

Try an example

A plain name is a yes or no condition. For more values, use a colon: Membership: Gold, Silver, None

Everything the system can do in response, such as a message, a price or a block.

Names the feature in Gherkin and test titles.

3. Decide each outcome: 8 combinations

Tick what should happen for each combination. Every combination has an outcome.

Full decision table
RuleValid usernameValid passwordAccount lockedLog inShow invalid credentials errorShow account locked message
R1YYY
R2YYN
R3YNY
R4YNN
R5NYY
R6NYN
R7NNY
R8NNN

4. Your tests: 4 instead of 8

Combinations with the same outcome were merged. A "-" means that condition makes no difference for that test, so pick any value.

Reduced decision table
TestValid usernameValid passwordAccount lockedExpected
R1--YShow account locked message
R2-NNShow invalid credentials error
R3YYNLog in
R4NYNShow invalid credentials error
Export as

One row per test with title, steps and expected result. Imports into TestRail, Xray, Zephyr or a spreadsheet.

How to use

How to use the Decision table generator

  1. 1Start from an example such as Login or Free shipping, or list your own conditions and possible outcomes.
  2. 2A plain condition name is yes or no. For more values, use a colon: "Membership: Gold, Silver, None".
  3. 3Tick what should happen for every combination. Any combination you cannot decide is a question for whoever owns the requirement.
  4. 4Use the reduced table as your tests: combinations with the same outcome are merged, and "-" means that condition makes no difference. Export it as test cases, Markdown or Gherkin.

What decision table testing is

Decision table testing is a black-box technique for business rules that combine several conditions. The table lists every combination of condition values as a rule, and for each rule, the actions the system should take. Each rule becomes a test case.

It is the right technique when the outcome depends on conditions together rather than separately: a discount that applies to members, but only on orders over a threshold, unless the item is already on sale. Testing each condition alone would never show what happens when they interact, and that is where business rule defects live.

The table finds requirement gaps before it finds defects

Filling in the full table forces a decision for every combination, including the ones nobody thought about. What should happen when an account is locked and the password is wrong? Should the user see the lockout message, or the invalid password message? Either answer is defensible. Not having an answer is the defect.

Rules left with no action ticked are flagged for exactly this reason. Take them back to whoever owns the requirement. It is the cheapest point at which to find a missing rule, because no code depends on the answer yet.

Full tables and reduced tables

A full table has one rule for every combination: two to the power of the number of yes-or-no conditions, so three conditions make eight rules and ten conditions make 1,024. Many of those rules turn out to share an outcome. If a locked account always shows the lockout message whatever the username and password, the four locked rules say the same thing.

Reducing the table merges rules that have the same actions and differ only in one condition, across every value that condition can take. The merged condition is shown as "-", meaning it does not matter. The reduced table has fewer tests and still covers every distinct outcome. The generator reduces greedily, so on large tables another valid reduction may be slightly smaller, but every reduction it produces is exact: each original combination maps to exactly one reduced rule with the same actions.

When a table gets too big

Every extra condition doubles a table of yes-or-no conditions. Beyond five or six conditions, check whether the rule really depends on all of them at once, or whether it splits into smaller independent rules that each deserve their own table. If the conditions are genuinely independent parameters rather than a single business rule, pairwise testing covers their interactions in far fewer tests.

QAble service

QA consulting

QAble reviews business rules with the people who own them and turns them into decision tables that close the gaps before development starts.

Explore the service
FAQ

Frequently asked questions

What is decision table testing with an example?

It lists every combination of conditions and the expected actions for each. For a login with three conditions (valid username, valid password, account locked) there are eight combinations. If a locked account always shows the lockout message, those four rules merge into one, and the table reduces to four tests.

How many rules does a decision table have?

The product of the number of values of each condition. For yes-or-no conditions that is 2 to the power of the number of conditions: 3 conditions give 8 rules, 4 give 16. A reduced table usually has far fewer.

What does the dash mean in a decision table?

That the condition does not matter for that rule: the outcome is the same whatever its value. It appears when rules are merged during reduction.

When should I use decision table testing?

When the expected outcome depends on a combination of conditions, as in pricing, eligibility, permissions, discounts, approvals and validation that spans several fields.

What is the difference between decision table testing and pairwise testing?

A decision table covers every combination of conditions for one business rule, with a specific expected outcome for each. Pairwise testing covers every pair of values across many independent parameters, accepting that it will not test every combination.

Is anything I enter sent to QAble?

No. The tables are built in your browser.

Need the edge cases found for you?

QAble testers work through the inputs, payment paths and data that break products in production, before your users find them.

Talk to QA Advisor