public void ShouldCheckTypeOfInstanceResultAfterCreateFromDoctorsController() { _doctorsController = new DoctorsController(_doctorRepository); var expectedType = typeof(ViewResult); var value = _doctorsController.Create(); Assert.IsInstanceOfType(value, expectedType); }
public void ShouldCheckTypeOfInstanceResultAfterCreateFromDoctorsController_WithFakeRepository() { _doctorsController = new DoctorsController(_fakeDoctorRepository); var expectedType = typeof(ActionResult); var value = _doctorsController.Create(new Doctor()); Assert.IsInstanceOfType(value, expectedType); }
public void Create() { // Arrange DoctorsController controller = new DoctorsController(); // Act ViewResult result = controller.Create() as ViewResult; // Assert Assert.IsNotNull(result); }