Chapter 5. Programmer Tests: Using TDD with ADO.NET

In this chapter, we demonstrate how to write programmer tests when implementing a data access layer using ADO.NET. We limit the scope of this chapter by implementing only functionality that is needed to implement the data access aspects of the Web service. (See Chapter 4 for a more complete discussion of the feature.) As you will see, not only do we have to implement the functionality associated with the feature, we have to augment the solution to be able to write tests appropriately. In later chapters, this implementation will evolve to address additional capabilities such as transactions, concurrency, and updates.

Testing the Database Access Layer

Testing a program that accesses data stored in ...

Get Test-Driven Development in Microsoft® .NET now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.