Got to debug is a bug, fix your error messages

time to read 1 min | 144 words

This is part of the RavenDB test suite.


It has a bug.

Can you see it?

One of the things that I learned when working on the Castle project is that errors are important. In fact, they are really important, so it is worth the time to check them very carefully.

In this case, this code would fail but won’t tell me why it is failing.

Changing it to this:


Means that I get the actual error message right there and then, no need to do anything special.