aboutsummaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)Author
2015-04-16Merge branch 'rspec-style'HEADmasterTeddy Wing
2015-04-16Add README & LICENSETeddy Wing
2015-04-15main.rb: Exit more quietly on Ctrl-CTeddy Wing
Otherwise it prints "Interrupt" and a traceback.
2015-04-15main.rb: Output our winner when we have oneTeddy Wing
2015-04-15Board: Determine winner in `#winner?`Teddy Wing
2015-04-14Flesh out the game loopTeddy Wing
* Use a new, currently empty `Board#winner?` method as our loop condition * Add `Player#insignia` so we can print the correct player insignia depending on who the current player is * Print the board and a prompt for coordinates * Switch the current player after a player finishes moving
2015-04-14Board: Fix #render methodTeddy Wing
Return the actual board in the right format instead of always returning 3 rows of 3 dots.
2015-04-14Player: Add a `#move` method to move a piece to a cell on the boardTeddy Wing
Also add `Board#update_cell` to facilitate player movement.
2015-04-14Player: Add `initialize` method, use insignia constantsTeddy Wing
Add an `initialize` method to get rid of our test errors and use the constants we created in 231060de4c493a9c6ba3510a9be4d405517af5c6 when creating new `Player`s.
2015-04-14Player: Add constants for player insignias ('X' & 'O')Teddy Wing
2015-04-14Add some empty test for Player movementTeddy Wing
Test some code for an API concept for player, ideas for tests of the `Player#move` method.
2015-04-14spec_helper: Move `require 'board'` to board_specTeddy Wing
We shouldn't be requiring all our files & classes in the spec_helper. It should just be used for test setup. We can require the modules we need for testing directly in the test files.
2015-04-14Board: Method to unintelligently convert string coordinates to arrayTeddy Wing
Take string coordinates in the form ":integer:,:integer:" and convert them to [integer, integer]. We'll be using these converted coordinate values to place a piece on the board.
2015-04-11Create main game loopTeddy Wing
* main.rb will be what we use to run the game. Add some setup and an idea for grabbing board coordinates to place a piece. * Add empty Player class to represent Xes and Os
2015-04-11Create a MiniTest::Unit version of the Board render testTeddy Wing
Will be writing both spec and TestUnit versions of the tests.
2015-04-11Board#render: return output instead of printingTeddy Wing
Don't print the grid directly. We'll do this in a separate display method or game loop area.
2015-04-11Board: initialize with a grid of dotsTeddy Wing
The board starts as a grid of dots represented by a 2-dimensional array.
2015-04-11Use specs, create BoardTeddy Wing
Use specs for testing, create a spec for the Board class. Simple functionality and test to print a grid of dots for the board.
2015-04-11Create test_helper, add trial test for BoardTeddy Wing
* Add test_helper.rb for includes * Add a test to sample test that initializes Board
2015-04-11Add .gitignoreTeddy Wing
Create an untracked directory for extra files.
2015-03-17Initial commit. Get tests working.Teddy Wing
Create a Rakefile to run tests and a sample test file.