Let see this code
class Car {
whell = new Whell();
run(){
this.whell.move();
}
}
How to make test to ensure the Car run whell correctly ?, above code is not possible to unit test. so we need to modify this code and create constructor to inject whell object.