Mock Data Provider

Many times it is necessary to be able to test each layer of an application individually. This task becomes specially difficult with the data access code and the unit tests since is complex to assure the results of the tests if each developer doesn’t have a private database.

To solve this problem I have developed a ADO.NET Data Provider that allows to test the data access code without accessing to the database.

The Mock Data Provider has two operation modes:
In the “recording” mode it acts of Proxy against another ADO.NET Data Provider and it records the results of all the executions against the database.
In the “mock” mode it returns the results that it registered previously in the “recording” mode, without being connected to the database.

In the conference that I will give on Thursday 24th I will make a complete demonstration of this tool meanwhile you can download the code from here together with a example of use.

About Rodolfo Finochietti

Uma's and Gino's father, and a programmer ;)

Posted on 08/16/2006, in .NET, Tools. Bookmark the permalink. Leave a comment.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: