ORMSwareTM is a proprietary quantitative modeling and programming system developed by US Army veteran Reginald Joules at Ushar Enterprises Inc, Littleton, Colorado, USA, with keen interest in national defense problems

Home Modeling Examples Programming Examples Contact Us


Logical Network Diagram of Code Testing Illustration

Coding. It's logic. Not magic.

There are 7 true/false switches in this ASP related to referral coupon numbers, which potential customers could enter in an [old] Pedal Magic order form for a discounted or free license:

  1. Valid
  2. Activated
  3. In GDC database
  4. Within expiration time limit
  5. Eligible price
  6. Referrer eligible
  7. Referrer rebated

For exhaustive testing, how many combinations of T/F settings of these switches need to be tried to be certain that the code is reliable? Off the cuff, one would think 2 ^ 7 = 128 combinations. However, while 128 combinations will indeed cover every possibility, 119 of those 128 combinations would be totally unnecessary to ensure exhaustive testing of the logic in this ASP.

Examine the network diagram below for the required tests of any given coupon number and the logic applied. The terminal/return nodes in the network shows all possible outcomes of any coupon number a potential customer might use. There are only 9 possible outcomes. Therefore, only 9 specific combinations need to be tried for exhaustive testing. For further discussion of this testing illustration, please watch any or all of our three ORMSware videos on software that are Correct by Construction.