I have to test an AngularJS app and I am trying to do the unit testing for the services. The services have functions that look like this:
getData: function(){
return $http.get(serviceRoot+'/getData/'+anotherService.id()).then(function(response) {
return secondService.validateServerJson(response.data.key);
}, function(error) {
return false;
})
},
is there a point to write a test for this since I am mocking the http requests?
Aucun commentaire:
Enregistrer un commentaire