/// <summary> /// Constructor for the Engine class. /// </summary> /// <param name="renderer">IRenderer object</param> /// <param name="inputProvider">IInputProvider object.</param> public Engine(IRenderer renderer, IInputProvider inputProvider) { this.inputProvider = inputProvider; this.renderer = renderer; this.scoreBoard = Scoreboard.Instance; this.wordDataBase = new WordDatabase(this.dataSerialization); this.wordFactory = new WordFactory(this.wordDataBase); this.gameLogic = new DefaultGameLogic(); this.gameLogic.Word = this.wordFactory.GetWord(Categories.IT); }
public void PlayerShouldNotBeNullOnDefaultGameLogicCreation() { var gameLogic = new DefaultGameLogic(); Assert.NotNull(gameLogic.Player); }
public void PlayerShouldBeOfTypePlayer() { var gameLogic = new DefaultGameLogic(); Assert.That(gameLogic.Player, Is.TypeOf(typeof(Player))); }
public void IsCheatedShouldFalseOnDefaultGameLogicCreation() { var gameLogic = new DefaultGameLogic(); Assert.IsFalse(gameLogic.IsCheated); }
public void GameStateShouldBeOfTypeGameState() { var gameLogic = new DefaultGameLogic(); Assert.That(gameLogic.GameState, Is.TypeOf(typeof(GameState))); }
public void DefaultGameLogicShouldNotBeNullOnCreation() { var gameLogic = new DefaultGameLogic(); Assert.NotNull(gameLogic); }
public void CurrentPlayerInfoShouldNotBeNullOnDefaultGameLogicCreation() { var gameLogic = new DefaultGameLogic(); Assert.NotNull(gameLogic.CurrentPlayerInfo); }
public void CurrentPlayerInfoShouldBeOfTypeGameInfo() { var gameLogic = new DefaultGameLogic(); Assert.That(gameLogic.CurrentPlayerInfo, Is.TypeOf(typeof(GameInfo))); }