DEV Community


Discussion on: Death by Interfaces?

baskarmib profile image
Baskarrao Dandlamudi

One benefit to use Interface is it provides good support for writing mock tests and today’s dependency injection is tied to interfaces. These are the reasons for their increased usage in today’s applications. 100% agree to your thoughts.

integerman profile image
Matt Eland Author

I agree. I thought of this when writing my article but forgot to work it into the base class vs interface discussion - many mocking frameworks can work with base classes instead of interfaces and some can even work with concrete classes.