Start here. This is the direct spoken answer to practice first.
Overview
A replacement is useful only if the component receives it through the same dependency boundary it uses in production.
I configure TestBed with the component and provide a fake or spy for the service or injection token it consumes. The fake implements the smallest public contract needed by the test and returns controlled values or failures. I retrieve dependencies from TestBed or the fixture injector rather than constructing a second instance that the component never uses.