public void It_should_ask_the_facebook_service_for_a_list_of_friends() { //Arrange //Act _controller.Index(); //Assert A.CallTo(() => _facebookService.GetFriends()).MustHaveHappened(Repeated.Exactly.Once); }
public IHttpActionResult GetFacebookFriends() { var friends = facebook.GetFriends(); if (!string.IsNullOrWhiteSpace(friends)) { return(Ok(friends)); } return(NotFound("You have no friends. :(")); }