O'Reilly logo

Fit for Developing Software: Framework for Integrated Tests by Ward Cunningham, Rick Mugridge

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 3. Testing Calculations with ColumnFixture Tables

We often want to test that calculations are being carried out correctly, according to some business rule. Tables of concrete examples help us to understand business needs and communicate what’s required. Here, we will focus on how to read such Fit tests; later, we will show how to write them.

We begin with two simple examples that test calculations by using tables of type ColumnFixture, which is designed to do this.

These tests are rather abstract in that they say nothing about how someone using the system under test will see the consequences of this business rule. In Chapter 4, we’ll see tests that are more aligned to the step-by-step use of the system under test.

3.1 Calculating Discount ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required