예제 #1
0
        public void MoveCodesParsed(string moveCode, int expectedFrom, int expectedTo, int promotionPiece)
        {
            var move = NotationHelper.ParseMoveCode(moveCode);

            Assert.AreEqual(expectedFrom, move.StartSquare);
            Assert.AreEqual(expectedTo, move.EndSquare);
            Assert.AreEqual(promotionPiece, move.PromotionPiece);
        }
예제 #2
0
 public void InvalidMoveCodesParseThrows(string moveCode)
 {
     Assert.Throws <ArgumentException>(() => NotationHelper.ParseMoveCode(moveCode));
 }