Distilling some ideas for keeping that data access code (and test code) tidy…

I just spent a while doing some refactoring. It turned out to be a very long while, probably much more than I would have originally estimated. (Part of the reason for that is builds and tests that take a long time…) The changes I made were somewhat haphazard at first, and I wasn’t sure why I thought…

0

Is IQueryable poisoning your interfaces?

Thanks indirectly to a comment on my previous post, today I read ‘IQueryable is tight coupling’ (disclaimer: his words). I feel like it contains an interesting mixture of truth and panic, and makes a fine discussion topic. The main interesting truth he mentions is: nobody implements IQueryable fully! Yes! If you’ve used an ORM, you’ve…

2

Unit Testing DbContexts and queries – the status quo

So here’s the scene. I’ve been working on unit testing for a solid day, my percent coverage is up, my code is better factored, and now I do my ‘what is the most untested class I have’ analysis one more time, and discover that it is… ‘BillingEntitiesContext’. BillingEntitiesContext is my subclassed DbContext for describing my…

3

The Entity Framework Leaking

‘Fluent Interfaces’ have been a bit of a buzz for probably long enough that I am not justified in buzzing about them. I was pretty excited when first seeing them applied to databases in form of NHibernate and also kind of excited to see all that code-first-ness come to Entity Framework, which had never really…

0