Tag Archives: MoQ

Mocking Entity Framework to unit test your data services

It’s not easy to write unit tests for services that use DbContext and DbSet<T> classes from Entity Framework (or Entity Framework Core), and there are complex solutions to approach this, like separating the data access layer completely, as I propose in my UnitOfWork-EntityFramework implementation. … Continue reading

Posted in Architecture, C# | Tagged , , , , , , | Leave a comment