Game Development Reference
In-Depth Information
this path and the next number, 74, sends you to NoPointsItemUnlocked via flow 9. A 42 in
the random number list chooses flow 11, which brings you once again to
HavePointsItemUnlocked . These flows extend the path to 1, 3, 4, 7, 9, 11, 7, 9, 11, 7, 9, 11.
The next random number to use is 13. This falls within the 6-15 range, which corre-
sponds to flow 6. That's the Exit flow, which goes to the OUT terminator. This marks
the end of this test path. The completed path is 1, 3, 4, 7, 9, 11, 7, 9, 11, 7, 9, 11, 6.
Once a path is defined, create the test cases using the data dictionary techniques
described in Chapter 11. To create an overview of this test, list the flows, actions, and
states in the order they appear along the path. List the flow number for each step in
parentheses at the beginning of each line, as follows:
IN_PointsItem
(1) Enter, NoPointsItemLocked
(3) GetPoints, GetPointsEffects, HavePointsItemLocked
(4) UnlockItem, UnlockEffects, HavePointsItemUnlocked
(7) PurchaseItem, GetItemEffects, NoPointsHaveItem
(9) DeleteItem, DeleteItemEffects, NoPointsItemUnlocked
(11) GetPoints, GetPointsEffects, HavePointsItemUnlocked
(7) PurchaseItem, GetItemEffects, NoPointsHaveItem
(9) DeleteItem, DeleteItemEffects, NoPointsItemUnlocked
(11) GetPoints, GetPointsEffects, HavePointsItemUnlocked
(7) PurchaseItem, GetItemEffects, NoPointsHaveItem
(9) DeleteItem, DeleteItemEffects, NoPointsItemUnlocked
(11) GetPoints, GetPointsEffects, HavePointsItemUnlocked
(6) Exit, OUT_PointsItem
Generating this path provided some expected results. The path starts with the IN and
ends with the OUT, which is mandatory. Flows with large percentages were selected
often, such as flows 9 and 11, which each have a 90% usage probability.
Did anything surprise you? Some flows and states didn't appear in this path at all.
That's okay for a single path. When you create a set of paths you should expect to
explore a wider variety of flows and states.
Was the flow longer than you expected? Flows 7, 9, and 11 appeared multiple times in
this path. This is not what you would expect from minimum or baseline path sets. It's
also interesting to note that those three flows form a loop. They were used three times
in a row before finally exiting and ending the path.
Search WWH ::




Custom Search