Category Archives: AutoMocking

The Dangers Of AutoMocking Containers

Louis Salin commented on my original post about the Ninject.RhinoMocks automocking container, and brought up a very good point. Here is his comment, reproduced in full: I’ve heard (or read…) that automocking is equivalent to taking weight loss pills while … Continue reading 

Also posted in .NET, Analysis and Design, AntiPatterns, C#, Craftsmanship, Quality | 5 Comments

Simplify Your Unit Tests With Automocking: Part 2 – Establishing Context

Following my helper methods in the base context specification class that we use, I decided to simplify the entire process of setting the context in which the tests are running. Specifically, I wanted to get rid of the constant declaration … Continue reading 

Also posted in .NET, Behavior Driven Development, C#, Ninject, Refactoring, RhinoMocks, Unit Testing | 3 Comments

Simplify Your Unit Tests With Auto Mocking: Part 1 – Helper Methods

After working on the Ninject.RhinoMocks automocking container, I started using it in my current project right away and it wasn’t long before I started simplifying the usage of it with helper methods in my base test class.   From “MockingKernel.Get<T>()” … Continue reading 

Also posted in .NET, Behavior Driven Development, C#, Ninject, Refactoring, RhinoMocks, Unit Testing | 8 Comments