Ejemplo n.º 1
0
        public void Setup()
        {
            _mockGameSessionStorage       = Substitute.For <IGameSessionStorage>();
            _mockGameStorage              = Substitute.For <IGameStorage>();
            _mockGameErrandStorage        = Substitute.For <IGameErrandStorage>();
            _mockGameSessionErrandStorage = Substitute.For <IGameSessionErrandStorage>();
            _mockGameSessionEventStorage  = Substitute.For <IGameSessionEventStorage>();

            _service = new GameSessionService(_mockGameSessionStorage, _mockGameStorage, _mockGameErrandStorage, _mockGameSessionErrandStorage, _mockGameSessionEventStorage);
        }
Ejemplo n.º 2
0
        public GameSessionService(IGameSessionStorage gameSessionStorage, IGameStorage gameStorage, IGameErrandStorage gameErrandStorage, IGameSessionErrandStorage gameSessionErrandStorage, IGameSessionEventStorage gameSessionEventStorage)
        {
            _gameSessionStorage       = gameSessionStorage;
            _gameStorage              = gameStorage;
            _gameErrandStorage        = gameErrandStorage;
            _gameSessionErrandStorage = gameSessionErrandStorage;
            _gameSessionEventStorage  = gameSessionEventStorage;

            _gameSessionEvents = new Subject <Event>();
        }
 public ErrandController(IErrandStorage taskStorage, IGameErrandStorage gameErrandStorage)
 {
     _taskStorage       = taskStorage;
     _gameErrandStorage = gameErrandStorage;
 }
 protected override void OnSetup()
 {
     _mockErrandStorage     = Substitute.For <IErrandStorage>();
     _mockGameErrandStorage = Substitute.For <IGameErrandStorage>();
     Controller             = new ErrandController(_mockErrandStorage, _mockGameErrandStorage);
 }