Esempio n. 1
0
        public void constructor_Empty()
        {
            EmptyPieceManager pm = new EmptyPieceManager(0, 0, new Game());

            Assert.IsTrue(pm.Owner == Players.None);
            Assert.IsTrue(pm.Type == PieceTypes.Empty);
        }
Esempio n. 2
0
        public void position_Correct(int x, int y)
        {
            IPieceManager pm = new EmptyPieceManager(x, y, new Game());

            Assert.AreEqual(pm.PieceXPosition, x);
            Assert.AreEqual(pm.PieceYPosition, y);
            pm = new PieceManager(new WhitePawn(new Point(x, y), new ChessBoard()), new Game());
            Assert.AreEqual(pm.PieceXPosition, x);
            Assert.AreEqual(pm.PieceYPosition, y);
        }