Example #1
0
        async public void GravarTarefaTest()
        {
            #region Given
            TarefaService service = MontarConstrutor();
            #endregion

            #region When
            _tarefaRepositoryMock.Setup(s => s.CriarAsync(It.IsAny <Tarefa>())).Returns(Task.FromResult(new TarefaTestBuilder().Default().Build()));
            var result = await service.CadastarTarefaAsync(new TarefaTestBuilder().Default().Build());

            #endregion

            #region
            result.Should().NotBeNull();
            result.DataEdicao.Should().BeNull();
            #endregion
        }