A ColumnFixture lets a Fit table check calculation-style business rules: each row supplies inputs, and expected results are compared with the fixture’s output. section 10.2.1
The header row tells Fit how to handle each column:
- A name such as left sets the matching public field on the fixture from each row’s cell. section 10.2.1
- A name such as result() marks an expected-result column; Fit calls that method and compares its return value with the row’s expected value. section 10.2.1
A calculator fixture
CalculatorFixture is an example of a class that subclasses fit.ColumnFixture and backs a fixture table. section 10.2.1
Figure 10.5. The column fixture table from figure 10.4 with explanations of the meaning of key elements of the table structure
See the fixture table’s header row and the roles of its key cells. section 10.2.1
