I would like to test myService initialisation which could be different depends on conditions:
service('myService', function(internalService){
if(internalService.param){ init1(); }
else { init2(); }
//...
});
I can mock internalService, but how to recreate myService?
Aucun commentaire:
Enregistrer un commentaire