public void Delete_ExistingId_Deleted() { var id = 1; _unitOfWorkMock.Setup(uof => uof.SchoolSubjectGenericRepository.Delete(id)); _sut.Delete(id); _unitOfWorkMock.Verify(uof => uof.SchoolSubjectGenericRepository.Delete(It.IsAny <int>()), Times.AtLeastOnce); }
public ActionResult DeleteConfirmed(int id) { _schoolSubjectsService.Delete(id); return(RedirectToAction("GetSchoolSubjects", "SchoolSubject", new { area = "Operator" })); }