Book Image

Mastering Entity Framework Core - Advanced Querying, Migrations and Testing [Video]

By : Sergey Barskiy
Book Image

Mastering Entity Framework Core - Advanced Querying, Migrations and Testing [Video]

By: Sergey Barskiy

Overview of this book

<p>You will start the course by exploring data validation and learn how to implement data validation inside your model using attributes. Then you will use validation inside MVC controllers and expose validations inside your MVC views in the user interface. Next you will delve into advanced query techniques. You will see how asynchronous code helps your applications scale better and explore query performance. Further, you will learn how to protect application data from concurrent access by multiple users, see how transactions enable changes to multiple tables and learn how to create an abstraction layer on top of Entity Framework by using the repository pattern.</p> <p>Next you will embrace migrations and embark on a journey designed to develop the database structure as your application evolves using Entity Framework Core migrations. Then you will create custom migrations that update database schemas and use custom scripts to perform migrations while protecting existing data during rename operations. Finally you will explore testing and set up a further learning path by writing unit and integration tests. You will see how to bring Entity Framework into a project based on an existing database. In conclusion, you will learn about additional areas Entity Framework core can be used in, and what types of data structure (besides RDBMS) can be accessed with EF Core.</p> <h2>Style and Approach</h2> <p>In a step-by-step manner, learn to use the latest open source features of Entity Framework Core in your .NET applications. Learn to perform advanced querying techniques, migrations, and testing. Understand everything you need to effectively start developing and managing data-driven applications using Entity Framework and make the best of your .NET APIs by integrating them with Entity Framework.</p>
Table of Contents (6 chapters)
Chapter 6
Testing and Runtimes
Content Locked
Section 2
Creating Unit Tests
The aim of this video is to insert new data into the database through web service calls, we need to add insert implementation to our Web API controller - Discuss why we need unit tests for our EF Core code - Learn how in-memory provider for EF core can facilitate unit testing - Create a unit test against a Web API controller using in-memory provider