public async void InvokeTest_DeleteApplication_ReturnsSuccess() { //Arrange var repository = new HealthCheckerRepository(); //Act var application = repository.GetApplicationByName("UpdatedTestApp"); await repository.DeleteApplication(application); var dbApplication = repository.GetApplicationByName("UpdatedTestApp"); //Assert dbApplication.Should().Be(null); }
public async void InvokeTest_UpdateApplication_ReturnsSuccess() { //Arrange var repository = new HealthCheckerRepository(); //Act var application = repository.GetApplicationByName("TestApp"); application.Name = "UpdatedTestApp"; var updatedApplication = await repository.UpdateApplication(application); var dbApplication = await repository.GetApplicationById(application.ApplicationId); //Assert dbApplication.Name.Should().Be(updatedApplication.Name); }