LaunchCode-Education-Archived / csharp-web-development

Unit 2 (C# Track) of the LC101 Curriculum, following fundamentals in JavaScript
https://education.launchcode.org/csharp-web-development/
GNU General Public License v3.0
5 stars 9 forks source link

Interfaces #82

Closed scottkuhl closed 3 years ago

scottkuhl commented 4 years ago

https://education.launchcode.org/csharp-web-development/chapters/interfaces-and-polymorphism/interfaces.html

8.2.3. Benefits of Using Interfaces

This section should mention another benefit in that it makes unit testing easier.

I am not all the way through the course yet, but at some point the students should create an interface for a dependent service like the database and learn how to unit test without actually calling into the database.

jimflores5 commented 3 years ago

Scott, thanks for the suggestion. We can easily add the unit testing benefit. However, at this point in the textbook, diving into the example of the dependent service seems like too big of an ask for the students. Similarly, even a more straightforward example would distract from the core flow of the chapter.