public void TestIfDeleteSportComplexCallsDeleteSportComplexInRepo() { // Arrange var repo = new Mock <ISportComplexRepository>(); var manager = new SportComplexAccess(repo.Object); // Act manager.DeleteSportComplex(It.IsAny <int>()); // Assert repo.Verify(x => x.DeleteSportComplex(It.IsAny <int>()), Times.Exactly(1)); }
public void TestIfRestoreSportAttributeCallsRestoreSportAttributeInRepo() { // Arrange var repo = new Mock <ISportComplexRepository>(); var manager = new SportComplexAccess(repo.Object); // Act manager.RestoreSportAttribute(It.IsAny <int>()); // Assert repo.Verify(x => x.RestoreSportAttribute(It.IsAny <int>()), Times.Exactly(1)); }
public void TestIfGetArchivedSportAttributesCallsGetArchivedSportAttributesInRepo() { // Arrange var repo = new Mock <ISportComplexRepository>(); var manager = new SportComplexAccess(repo.Object); // Act manager.GetArchivedSportAttributes(); // Assert repo.Verify(x => x.GetArchivedSportAttributes(), Times.Exactly(1)); }
public void TestIfUpdateHallCallsUpdateHallInRepo() { // Arrange var repo = new Mock <ISportComplexRepository>(); var manager = new SportComplexAccess(repo.Object); // Act manager.UpdateHall(It.IsAny <Hall>()); // Assert repo.Verify(x => x.UpdateHall(It.IsAny <Hall>()), Times.Exactly(1)); }