Several posts have been made lately concerning testing NHibernate Mappings. I thought I would share what I have done for the past few months. I create a test fixture for each class mapped in NHibernate. The tests in the fixture test loading, updating, saving, and deleting through NHibernate. Initially, I only tested loading, but later […]
Author Archives: ChrisEdwards
Testing NHibernate Mappings
Don’t Forget the Acceptance Tests!
Our tester recently informed me that several stories we had completed in a previous iteration were failing tests. The functionality simply was not working. To make matters worse, at least one of the stories was actually coded and marked complete by me! I was dumbfounded. How could I mark a story complete when it was […]
Agility Depends on Good Design and Complete Test Coverage
I have a very different approach to TDD. On my project, we hold a group design session before we write any tests or code. In that design session, we determine the object structure and bombard our design with edge cases and such. We continue modifying it on the whiteboard till it satisfies all the requirements. […]
Importance of Treating Unit Tests as First Class Code
On my previous project, we had a rather large set of unit tests. This collection of tests grew over time and we neglected to maintain them with the fervency in which we maintained our production code. This quickly came back to haunt us. Making sweeping changes to our codebase became painful because our tests were […]
TDD: Is -Just Make It Pass- Too Mundane?
In Test-Driven Development, I used to think it was a waste of time to write only enough code to make a test pass. I felt that if the code was not completely correct, why should I write it? Now, I feel differently. Some of the examples you will encounter while learning about TDD may seem […]