Esempio n. 1
0
        public void Not_capture_pawn_aside(char attackCol, int attackRow, char defCol, int defRow)
        {
            var bishopPostions = new PiecePostition(attackCol, attackRow);
            var pawnPostions   = new PiecePostition(defCol, defRow);
            var sut            = new PieceCapture(bishopPostions);

            Assert.False(sut.IsCapture(pawnPostions));
        }
Esempio n. 2
0
        public void Detect_pawn_capture_when_in_any_diagonal(char attackCol, int attackRow, char defCol, int defRow)
        {
            var bishopPostions = new PiecePostition(attackCol, attackRow);
            var pawnPostions   = new PiecePostition(defCol, defRow);
            var sut            = new PieceCapture(bishopPostions);

            Assert.True(sut.IsCapture(pawnPostions));
        }
Esempio n. 3
0
        public void Not_capture_pawn_in_front()
        {
            var bishopPostions = new PiecePostition('H', 1);

            var pawnPostions = new PiecePostition('H', 3);
            var sut          = new PieceCapture(bishopPostions);

            Assert.False(sut.IsCapture(pawnPostions));
        }