Summary
This chapter was entirely dedicated to the concepts of testing and unit testing. After a brief introduction, where we explained the meaning of these concepts and the various testing practices available, we spent some valuable time learning how to implement them properly.
We started focusing on back-end testing with the help of the xUnit.net testing tool. Such an approach required us to create a new test project, where we implemented our first back-end unit tests. While working at it, we learned the importance of some test-related concepts, such as mocking, which we used to emulate the behavior of our ApplicationDbContext
class to provide some in-memory data instead of using our SQL Server data source.
The back-end testing approach greatly helped us to understand the meaning of TDD and its similarities and differences vis-à-vis the BDD approach, which is a distinctive front-end testing practice.
Such a comparison guided us to Angular, where we used the Jasmine...