test/test-board.rb in shogi-ruby-0.0.9 vs test/test-board.rb in shogi-ruby-0.1.0
- old
+ new
@@ -131,32 +131,32 @@
end
assert_raise Shogi::UndefinedPieceError do
@board.move("+2726AA")
end
assert_raise Shogi::MoveError do
- assert_false(@board.move("+2726HI"))
+ @board.move("+2726HI")
end
assert_raise Shogi::MoveError do
- assert_false(@board.move("+2827HI"))
+ @board.move("+2827HI")
end
assert_raise Shogi::MovementError do
- assert_false(@board.move("+2826HI"))
+ @board.move("+2826HI")
end
assert_raise Shogi::MoveError do
- assert_false(@board.move("+2625FU"))
+ @board.move("+2625FU")
end
assert_raise Shogi::MovementError do
- assert_false(@board.move("+2725FU"))
+ @board.move("+2725FU")
end
assert_raise Shogi::MoveError do
- assert_false(@board.move("-4131KI"))
+ @board.move("-4131KI")
end
assert_raise Shogi::MovementError do
- assert_false(@board.move("+8855KA"))
+ @board.move("+8855KA")
end
assert_raise Shogi::MovementError do
- assert_false(@board.move("-1115KY"))
+ @board.move("-1115KY")
end
assert_nothing_raised do
@board.move("+7776FU")
@board.move("-4132KI")
@@ -176,11 +176,11 @@
P+
P-
EOT
assert_raise Shogi::MovementError do
- assert_false(@board.move("+8833UM").move("-2233KA").move("+0016FU"))
+ @board.move("+8833UM").move("-2233KA").move("+0016FU")
end
end
def test_move_csa_chain
assert_nothing_raised do
@@ -241,10 +241,10 @@
def test_move_csa_promote
@board.move("+7776FU", :csa)
@board.move("-3334FU", :csa)
assert_raise Shogi::MovementError do
- assert_false(@board.move("+2726TO", :csa))
+ @board.move("+2726TO", :csa)
end
assert_nothing_raised do
@board.move("+8822UM", :csa)
end
assert_equal(<<-EOT, @board.to_csa)