Exemplo n.º 1
0
        public void Should_Get_All_Professionals_With_Success()
        {
            //Act
            var response = _professionalAppService.GetAllProfessionals(new GetAllProfessionalsDto()
            {
                PageSize = 10
            });

            //Assert
            Assert.False(LocalNotification.HasNotification());
            response.Items.Count.ShouldBe(1);
        }
Exemplo n.º 2
0
        public IActionResult Get([FromQuery] GetAllProfessionalsDto requestDto)
        {
            var response = _professionalAppService.GetAllProfessionals(requestDto);

            return(CreateResponse <ProfessionalDto, ComposeKey <Guid, decimal> >()
                   .FromErrorEnum(ProfessionalDto.Error.GetAllProfessional)
                   .WithMessage(AppConsts.LocalizationSourceName, ProfessionalDto.Error.GetAllProfessional)
                   .WithDto(response)
                   .Build());
        }