public async Task IfQuizNull_False() { var command = new CreateResultCommand(null); var handler = new CreateResultHandler(_mock.Object); var result = await handler.Handle(command, CancellationToken.None); Assert.IsFalse(result); }
public async Task IfIdHasValue_False(string value) { var command = new CreateResultCommand(new QuizResult { _id = value }); var handler = new CreateResultHandler(_mock.Object); var result = await handler.Handle(command, CancellationToken.None); Assert.IsFalse(result); }
public async Task ResultIdNullOrEmpty_True(string value) { var command = new CreateResultCommand(new QuizResult { _id = value }); var handler = new CreateResultHandler(_mock.Object); var result = await handler.Handle(command, CancellationToken.None); Assert.IsTrue(result); }