Writing Tests for Data Access Code

Writing tests for data access code is hard because we have to find answers to many difficult questions such as:

  • What kind of tests should we write?
  • How should we configure our tests?
  • What should we test?
  • How can we write tests that test the right thing, and are both easy to read and maintain?

The thing is that if we make wrong choices, our tests might be useless, hard to read, and "impossible" to maintain.

Unfortunately, I had to learn this in the hard way.

That is why I wrote this tutorial and shared the lessons that I have learned with you. I hope that this tutorial helps you to avoid making the same mistakes.

Introducing: Writing Tests for Data Access Code

This five part tutorial consists of the following blog posts: