public void JoinTheMeeting() { Guid userId = Guid.NewGuid(); MeetingModel createdMeeting = meetingAppService.CreateMeeting(facilitatorId); MeetingModel joinedMeeting = meetingAppService.JoinTheMeeting(createdMeeting.Id, userId); Assert.That(joinedMeeting, Is.EqualTo(createdMeeting)); Assert.IsFalse(joinedMeeting.UserIsTheFacilitator); AssertThatTheQuestionsOfTheJoinedMeetingAreEqualToTheQuestionsOfTheCreatedMeeting(joinedMeeting, createdMeeting); }
public IActionResult JoinTheMeeting(Guid meetingId, Guid userId) { try { MeetingModel meeting = meetingAppService.JoinTheMeeting(meetingId, userId); return(Ok(meeting)); } catch (NonExistentMeetingException) { return(BadRequest()); } }