public void GetList_Void_ReturnFacultyList() { var list = new List <FacultyItem> { _faculty }; Mock.Get(_facultyRepository).Setup(x => x.GetList()).Returns(list); var result = _facultyService.GetList(); Assert.AreEqual(result.Count, list.Count); }
/// <summary> /// Список факультетов. /// </summary> /// <returns></returns> public ActionResult List() { Access.CheckAccess("Faculty.Reader"); return(View("List", _facultyService.GetList().OrderBy(x => x.ShortName).ThenBy(x => x.FullName).ToList())); }