Section 11.1. Business Forms


11.1. Business Forms

It can be convenient to have a test that is similar in structure to a standard business form, such as an invoice. This reduces the gap between the business world and the tests, making it easier for businesspeople to write and to read the tests.

For example, Figure 11.1 shows a report for a Fit table that is based on an invoice. The number of rows in the table depends on the number of order items; here, there are two.

Figure 11.1. A Table Corresponding to an Invoice


Programmers

The fixture code for the tests here is given in Section 29.2 on p. 248.


Questions & Answers

Q1:

What if much of the information on the form is fixed and irrelevant to the test, such as "Delivered to"?

A1:

Some of the fixed information, such as "Delivered to," is helpful in reading the test, so it is useful to include in the table. Having it laid out in a similar way to the printed form will mean that it's familiar and thus easy to read.

But there's no need to include information in the Fit table that is not needed to understand the rest of the contents of the form. For example, there would be no point in legal information about delivery that's printed at the bottom of the form.



    Fit for Developing Software. Framework for Integrated Tests
    Fit for Developing Software: Framework for Integrated Tests
    ISBN: 0321269349
    EAN: 2147483647
    Year: 2005
    Pages: 331

    flylib.com © 2008-2017.
    If you may any questions please contact us: flylib@qtcs.net