public void ViewLessonWithNullUrl() { var controller = new LessonsController(); var result = controller.ViewLesson(null) as RedirectResult; Assert.IsNotNull(result); Assert.AreEqual("/", result.Url); }
public void ViewLessons() { var controller = new LessonsController(); var result = controller.ViewLessons(1, 1) as ViewResult; var model = controller.ViewData.Model as List<LessonsViewModel>; Assert.IsNotNull(model); }