public async Task <Consultant> Handle(RegisterConsultantCommand request, CancellationToken cancellationToken)
        {
            var consultant = _mapper.Map <Consultant>(request);

            consultant.Availability = "Available";
            return(await _repository.CreateAsync(consultant, request.Password).HidePassword());
        }
        public async Task GivenAnUser_WhenCreateAsync_ThenReturnUserEntity()
        {
            var consultant = ConsultantFactory.ValidConsultant();
            var password   = "******";

            var result = await _repository.CreateAsync(consultant, password);

            result.Should().BeOfType <Consultant>();
            result.Id.Should().Be(consultant.Id);
            result.Username.Should().Be(consultant.Username);
            result.Email.Should().Be(consultant.Email);
            result.Location.Should().Be(consultant.Location);
            result.Availability.Should().Be(consultant.Availability);
            result.NumberOfTickets.Should().Be(consultant.NumberOfTickets);
            result.Skill.Should().Be(consultant.Skill);
        }