Browse by Tags

All Tags » TDD » C# (RSS)
Mocking HttpRequest and HttpResponse is not complicated with HttpRequestBase and HttpResponseBase introduced in ASP.NET. I had to mock ServerVariables property of HttpRequest and run into an issue – I was accessing an indexer property and didn’t know...
Posted by Sean Feldman | 2 comment(s)
Filed under: ,
A few years ago I have blogged about Singletonitis . Another place, different people, yet the same problem appears again – singletonitis. The issues I have outlined back then where 1. Testing 2. Difficulty to replace implementation 3. Requirement to track...
Posted by Sean Feldman | 5 comment(s)
Filed under: , , ,
Row tests are fun. You can simulate various inputs with expected outputs and execute them all with a single observation (test). The problem for myself was always the fact that when this was done, the only way to accomplish it was to merge the logical...
Posted by Sean Feldman | with no comments
Filed under: ,
I was working on some code today, when run into a pitfall with Moq. This was probably my misreading of documentation. The component I was testing looked somewhat like the code below public class SomeOtherType { private readonly ISomeType someType; public...
Posted by Sean Feldman | 5 comment(s)
Filed under: , ,
More Posts