public void DirectLogin() { //Act IActionResult result = controller.DirectLogin(); //Assert Assert.NotNull(result); }
public void Task_Ticket_Return_OkResult() { Assert.Throws <NullReferenceException>(() => { var controller = new TicketController(); var UserName = "******"; var Password = "******"; var data = controller.DirectLogin(UserName, Password); Assert.IsType <RedirectToActionResult>(data); }); }