public void GivenUserConnectedWhenGetSessionThenReturnSessionAggregate() { _eventsStore.Store(new UserConnected(SessionId, UserId, DateTime.Now)); var session = _repository.GetSession(SessionId); Check.That(session).IsNotNull(); }
private void Setup() { //driver = BuildFireFoxDriver(); this._driver = BuildChromeDriver(); // this.portal = new EgifterPortal(driver); this._portal = new FakePortal(_driver); var session = _sessionsRepository.GetSession(); _portal.NavigateTo(); SetAuthCookie(session); }
public Task <ActionResult <GenerationsViewModel> > AdvanceGenerationsAsync(Guid id, [FromBody] ForewardGenerationsInputModel inputModel = null) => Task.Run <ActionResult <GenerationsViewModel> >(() => { var session = _repository.GetSession(id); if (session == null) { return(NotFound()); } if (!session.IsActive) { return(BadRequest()); } var viewModel = session.AdvanceGenerations(inputModel?.GenerationsCount ?? 200); return(Ok(viewModel)); });