Skip to content

Commit

Permalink
Revert prior change -- forgot :x.to_s == 'x'
Browse files Browse the repository at this point in the history
  • Loading branch information
cymen committed Feb 16, 2012
1 parent e1662b3 commit 6914520
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 10 deletions.
4 changes: 0 additions & 4 deletions lib/tic_tac_toe_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,6 @@ def get_players
[:x, :o]
end

def get_player_labels
['X', 'O']
end

def turn board
first, second = get_players
(board.count(first) == board.count(second)) ? first : second
Expand Down
6 changes: 0 additions & 6 deletions spec/tic_tac_toe_helper_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,6 @@ class TicTacToeHelperTester
players.uniq.count.should eq(2)
end

it "returns the two player labels" do
labels = TicTacToeHelperTester.new.get_player_labels
labels.count.should eq(2)
labels.uniq.count.should eq(2)
end

it "determines current turn based on board" do
TicTacToeHelperTester.new.turn(Board.new).should eq(:x)
TicTacToeHelperTester.new.turn(Board.new [:x]).should eq(:o)
Expand Down

0 comments on commit 6914520

Please sign in to comment.