BMI Calculator: Testing
Testing should be done at each step in the coding process and as well as at the end.
In addition to making sure that the program compiles, at each step certain aspects of
the program should be checked.
Testing done in Step 1: Program Skeleton
- Verify that the output box and main window show up when the program is run.
Testing done in Step 2: Input
- Try regular input: enter some reasonable numbers and verify that the values are
read correctly.
- Try bad input: enter "unreasonable" numbers, for example, negative integers,
zero, non-integer values. Comment assumptions as necessary.
Testing done in Step 3: Output
- Make sure the format of the output is as desired.
- Verify that the temporary values are printed out as expected.
Testing done in Step 4: Compute BMI
- Run the program several times with different input and verify (using a
calculator) that the program is computing the BMI correctly.