public void Create_ReturnsAViewResult() { //Arrange GuestAttendeesController guestAttendeesController = new GuestAttendeesController(context); //Act var result = guestAttendeesController.Create(); //Assert Assert.IsType <ViewResult>(result); }
public async void CreateAdd_RedirectToActionResult() { //Arrange GuestAttendeesController guestAttendeesController = new GuestAttendeesController(context); //Act var result = await guestAttendeesController.Create(new GuestAttendee() { Id = 2, LastName = "Lycan", FirstName = "Loyd", ContactNumber = "+447575324574", EmailAddress = "*****@*****.**", EventId = 1, }); //Assert Assert.IsType <RedirectToActionResult>(result); }