Beispiel #1
0
        public void Sistema_Deveria_Buscar_Todos_Os_Reuniao()
        {
            //Arrange
            Reuniao resultReuniao = _reuniaoService.Alocacao(_reuniaoDefault);

            //Action
            List <Reuniao> resultGetAll = _reuniaoService.GetAll();

            //Assert
            var ultimoReuniao = resultGetAll[resultGetAll.Count - 1];

            resultGetAll.Should().NotHaveCount(0);
            resultGetAll.Should().HaveCount(1);
            ultimoReuniao.Should().Equals(_reuniaoDefault);
        }
        public void GetAll_Deveria_Retornar_Todos_Os_Reunioes()
        {
            //Arrange
            List <Reuniao> _reuniaoDefaultList = ReuniaoObjectMother.DefaultList;

            _reuniaoRepositoryMockObject.Setup(p => p.GetAll()).Returns(_reuniaoDefaultList);

            //Action
            var resultReunioes = _Reunioeservice.GetAll();

            //Assert
            _reuniaoRepositoryMockObject.Verify(x => x.GetAll());
            resultReunioes.Should().NotBeEmpty();
            resultReunioes.Should().HaveCount(3);
        }