static IGameEngine GetDefaultGameEngine(int boardSize)
        {
            IBoard board = new Board(boardSize, boardSize);

            //create 2 players
            IList <IPlayer> players = new List <IPlayer>();
            IPlayer         player1 = new MockHumanPlayer("Bob", 'X', board);
            IPlayer         player2 = new MockPlayer("Sue", 'O', board);

            players.Add(player1);
            players.Add(player2);

            GameEngine engine = new GameEngine(players, board)
            {
                GameChecker = new MockGameChecker()
            };

            return(engine);
        }
Ejemplo n.º 2
0
        public void TestMockHumanPlayerIsNotComputer()
        {
            PlayerBase p = new MockHumanPlayer("Jimmy", 'X', null);

            Assert.False(p.IsComputer);
        }