public async Task UpdateAnswerAsync_AnswerIsPreviouslySeeded_UpdatesAnswer() { QuestionAnswer updatedAnswer; QuestionAnswer newAnswer; using (var uow = unitOfWorkProvider.Create()) { newAnswer = Initializer.AnswerJavaEeRedHat; newAnswer.Text = "I dont know"; repository.Update(newAnswer); await uow.Commit(); updatedAnswer = await repository.GetAsync(Initializer.AnswerJavaEeRedHat.Id); } Assert.IsTrue(newAnswer.Text.Equals(updatedAnswer.Text)); }
public bool QuestionAnswerEdit(QuestionAnswer question) { return questionAnswerRepository.Update(question); }