How do you pass parameters to a constructor that you never call? Try dependency injection. Source code available at: github.com/JasperKent/Depende...
Пікірлер: 15
@CodingTutorialsAreGo2 жыл бұрын
Let me know what other .NET Core features you'd be interested in. Source code at: github.com/JasperKent/Dependency-Injection Remember to subscribe at kzbin.info/door/qWQzlUDdllnLmtgfSgYTCA And if you liked the video, click the 👍.
@SharafMansour2 жыл бұрын
This is not a dream. You are a true savior.
@Praveen.Kumar.2 жыл бұрын
Always enjoy watching your videos
@wenchaojie81712 жыл бұрын
Your tutorials are very helpful! Thank you so much!
@CiaranCorrigan862 жыл бұрын
Thank you very much for this. Really clear and informative.
@rehmanshahyan Жыл бұрын
Thank you very much for this.
@tomjones9842 жыл бұрын
Just found your channel yesterday whilst looking for something regarding EF, and subscribed because I've found the videos to be very interesting, clear and informative; one thing's bugging me though...what do you store in the tiny colourful tubs? - An easily distracted developer
@CodingTutorialsAreGo2 жыл бұрын
Knick-knacks. Paperclips, batteries, cable ties ... Oddly, you're not the first to ask.
@user-gx4ju2ow6o6 ай бұрын
Which keyboard do you use can you please tell ? Love the sound
@Chapali9a2 жыл бұрын
Any possibility of a Unit Testing series?
@CodingTutorialsAreGo2 жыл бұрын
Unit Testing crops up in quite a few videos - because it's such an integral part of software development. But I'll put it on the list to do an in-depth series.
@gogolmbrakata91012 жыл бұрын
Hello, why do we have an injection of a DbContext, using the croncret type of the object, instead of some thing like IDbContext ?? can we speak about dependency injection without using any interface implemented by the concret class object expected ??
@CodingTutorialsAreGo2 жыл бұрын
Yes, you're right. We inject through an interface, allowing alternative implementations, or though a concrete class. For testing, we can either wrap the DbContext in a repository and mock that, or make our derived DBConext a base class from which we derive a mock, or use the standard DbContext configured for an in-memory DB (see kzbin.info/www/bejne/gHzcpXSaqLyUh9U)
@gogolmbrakata91012 жыл бұрын
@@CodingTutorialsAreGo Thank you
@reverendbluejeans17482 жыл бұрын
This tutorial would not have helped me learn what dependency injection is. A simplified example using asp.net would have helpted.