public void GetRaceDetails() { //Races details id cannot be null, if this test fails, //it means that that the method Details() doesn't work or the races table is empty (or no conn to database) RacesController races = new RacesController(); ActionResult result = races.Details(1); Assert.IsInstanceOfType(result, typeof(ViewResult)); }
public RacesControllerTests() { serviceMock = new Mock <IRacesService>(); loggerMock = new Mock <ILoggingService>(); controller = new RacesController(serviceMock.Object, loggerMock.Object); }
public void Initialize() { this._racesController = new RacesController(this._raceServiceMock.Object); }