public void GetDozenByQuantity_Test() { lotoManiaControllerTest = new LotoManiaController(mockwebService.Object, mockRepo.Object, mockLog.Object, mockLotteryService.Object); var result = lotoManiaControllerTest.GetDozenByQuantity(); Assert.IsType <OkObjectResult>(result.Result); }
public void GetDozenByQuantity_ThrowsException_Test() { mockRepo.Setup(m => m.GetAll()).Throws <Exception>(); lotoManiaControllerTest = new LotoManiaController(mockwebService.Object, mockRepo.Object, mockLog.Object, mockLotteryService.Object); var result = lotoManiaControllerTest.GetDozenByQuantity(); Assert.IsType <NotFoundObjectResult>(result.Result); }