Testing data access
Over the years, Entity Framework has strived to become unit testable and gives developers a better level of confidence when working with data access.
Building on when we created a sample database with Entity Framework Core in Chapter 5, in this section, we’ll cover a simple way to use a SQLite in-memory database to confirm the functionality of our application… even though we don’t have a database connection. Using the in-memory provider option, Microsoft has recommended avoiding this approach and using either SQLite to conduct database calls or using a production (or better, a QA) database for our queries.
Avoid in-memory providers
Since in-memory is an extremely simplistic implementation of a database, Microsoft has recommended using alternative methods for testing and avoiding the in-memory provider for databases. Refer to the following URL for additional details: https://learn.microsoft.com/en-us/ef/core/testing/testing-without-the...