コード例 #1
0
 public void TestSendClick()
 {
     var view = new BoardViewer();
     view.Show();
     view.sendClick("Aa1");
     view.Dispose();
 }
コード例 #2
0
 public void TestFixColorsNull()
 {
     var view = new BoardViewer();
     var list = new List<string>();
     list.Add("Fb1");
     view.fixColors(list);
 }
コード例 #3
0
 public void TestNotMovePiece()
 {
     var view = new BoardViewer();
     view.Show();
     view.sendClick("Eb4");
     view.sendClick("Eb4");
     var cell = view._board.GetCell("Eb3");
     Assert.IsNull(cell.GetPiece());
     Assert.IsNotNull(view._board.GetCell("Eb4").GetPiece());
     view.Dispose();
 }
コード例 #4
0
 public void TestMovePiece()
 {
     var view = new BoardViewer();
     System.Threading.Thread.Sleep(1000);
     view.Show();
     System.Threading.Thread.Sleep(1000);
     view.sendClick("Eb4");
     System.Threading.Thread.Sleep(1000);
     view.sendClick("Eb3");
     System.Threading.Thread.Sleep(1000);
     var cell = view._board.GetCell("Eb3");
     System.Threading.Thread.Sleep(1000);
     Assert.IsNotNull(cell.GetPiece());
     System.Threading.Thread.Sleep(1000);
     Assert.IsNull(view._board.GetCell("Eb4").GetPiece());
     System.Threading.Thread.Sleep(1000);
     view.Dispose();
 }