Also known as a Cause and effect table, a decision table is a representation of different combinations of inputs in line with their associated actions or outputs. They are used to fuel logic by embedding them with codes or program.
A decision table’s property of dealing with large number of combinations of input with varied responses comes handy in the field of software testing.
Let us suppose as professional testers we are testing the efficacy of online ticket booking option for a railway app.
|Input condition||Value 1||Value 2||Value 3|
In order to test the efficacy of the trains button, we will have to consider following case scenarios for enabling the trains button option which will take us to the list of all trains running between the different destinations.
Case 1: If we don’t select any trains from the “TRAINS FROM” drop down value and select options only from the “TRAINS TO” drop down menu, the “TRAINS” button will remain disabled. This is represented by the false value for the Trains button in column designated as Value 1.
Case 2: If we don’t select any trains from the “TRAINS TO” drop down value and select options only from the “TRAINS FROM” drop down menu, the “TRAINS” button will again remain disabled. This is represented by the false value for the Trains button in column designated as Value 2.
Case 3: If we select options from both the “TRAINS FROM” and the “TRAINS TO” menus, then only the “TRAINS” button will get enabled. This is illustrated by the truth values for all rows in column designated as Value3. Such tables are used in the form of iterations and serve as input tables for succeeding tabular cycles.
The importance of decision table testing becomes more highlighted when we consider the fact that instead of a couple of input conditions to test, as shown in the above case, there are 100s of them with their innumerable combinations to consider, as seen with filling of online web forms. It goes without saying that not all the possible combinations will be utilised for testing but a select few is considered for testing the authenticity of various form filling based apps or websites.