Test Data Builder

Unit Testing Databases with tSQLt Part 6 – testing a SELECT stored procedure

7 December 2011

In Part 5, we looked at writing tests to prove that one stored procedure calls another and how test-driven development can help us refactor code. In Part 6 we are going to write some initial tests for a stored procedure that returns data as part of the Log4TSql open source logging library for SQL Server 2005+ [...]

Read the full article →

Unit Testing Databases – Adapting the Test Data Builder Pattern for T-SQL

30 November 2011

One of the bigger obstacles to practising test-driven development, can be the perceived pain of building complex objects over and over again. This can be particulalrly frustrating when you have to construct an object with lots of attributes, most of which are irrelevant to any single test. For this reason, I am a fan of [...]

Read the full article →