I am new to Spring. What I understand from dependency injection is that it is the way by which an object can be created by container. We don't need to use 'new' operator.
I am not getting the benefits of Depenedency Injection. I read that it hepls us in
testing our code.
Can somebody please explain me how it helps in testing with the help of an example