Delivery and Deployment

TH11 Writing Testable Code and Resolving Dependencies - DI Kills Two Birds with One Stone

10/10/2019

11:00am - 12:15pm

Level: Intermediate

Miguel Castro

MRD

President

Melvicorp LLC

Dependency Injection is one of those terms that advanced programmers throw out with an expectation and assumption of full understanding on the part of the receiver. However, I constantly get asked by attendees, students, and clients to please recommend a good DI product and show them how to use it; and when I proceed to start talking about the subject, it becomes immediately apparent that many don't even know what they're asking about. It's easy to get infatuated by a cool buzz phrase, especially when you hear so many others using it. But to truly understand something you need to start by understanding the problem spaces that it is trying to solve. To write testable software, you need to understand and embrace abstractions and injecting them. But then you introduce the problem of having to resolve dependency chains. This is where using a DI container helps you solve both these issues. Come and I'll show you how to make your code testable and maintainable with the help of a DI container. If this is something your organization has not fully embraced yet, come and prepare for a tremendous wow factor.

You will learn:

  • Demonstrating problem code
  • Embracing abstractions for across-the-board testability
  • Using a full-featured DI container