This project is a two-player game of chess played in the terminal. This game was written in Ruby following the principles of object-oriented design and thorough testing.
Features of this chess game include the following:
- your current game can be saved, and you can load a previously saved game using JSON;
- the game does not allow illegal moves, including those would leave or place the king in check; and
- the board shown in the console rotates for each player.
This project is part of the The Odin Project curriculum.
- Fork this repository on GitHub.
- Clone your forked reposity onto your local computer.
- To play the game,
cdinto the project folder and typeruby play.rb.
- Fork this repository on GitHub.
- Clone your forked reposity onto your local computer.
- To run the tests, you need to have
rspecinstalled.- First, check to see if
rspecis already installed by typingrspec --versioninto the command line. - If the response is similar to the following, then you already have
rspecinstalled and can continue.RSpec 3.8 - rspec-core 3.8.0 - rspec-expectations 3.8.2 - rspec-mocks 3.8.0 - rspec-support 3.8.0
- If you do not see output similar to the above, then you need to install
rspecby typinggem install rspecinto the command line. - Now, run
rspec --versionagain to ensure that it installed correctly.
- First, check to see if
- Use
cdto move into the main directory and then enterrspecto run the tests.
- Ruby 2.5.3
- RSpec 3.8