public void ShouldRequireValidProjectId()
        {
            var command = new RemoveProjectParticipantCommand {
                ProjectId = 99, ParticipantEmail = "test@local"
            };

            FluentActions.Invoking(() => SendAsync(command)).Should().Throw <NotFoundException>();
        }
Ejemplo n.º 2
0
        public async Task <ActionResult> RemoveParticipant(int id, RemoveProjectParticipantCommand command)
        {
            if (id != command.ProjectId)
            {
                return(BadRequest());
            }

            await Mediator.Send(command);

            return(NoContent());
        }