Sha256: d8a05483ed79d2788cc088513d0b01ee8d226045021feb4718e54d264a4b0dce

Contents?: true

Size: 366 Bytes

Versions: 8

Compression:

Stored size: 366 Bytes

Contents

require 'test_helper'

class ChessTest < Minitest::Test
  def test_cant_castling
    game = Chess::Game.load_fen('2r1k2r/pR2p2p/2pn2Nb/P2p1p2/8/1P2P3/2PP4/2BQK3 b k - 1 3')
    assert_raises(Chess::IllegalMoveError) do
      game << 'O-O'
    end
    game = Chess::Game.load_fen('2r1k2r/pR2p2p/2pn3b/P2p1p2/8/1P2P3/2PP4/2BQK3 b k - 1 3')
    game << 'O-O'
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
chess-0.4.0 test/test_particular_situations.rb
chess-0.3.6 test/test_particular_situations.rb
chess-0.3.5 test/test_particular_situations.rb
chess-0.3.4 test/test_particular_situations.rb
chess-0.3.3 test/test_particular_situations.rb
chess-0.3.2 test/test_particular_situations.rb
chess-0.3.1 test/test_particular_situations.rb
chess-0.3.0 test/test_particular_situations.rb