Skip to content

Instantly share code, notes, and snippets.

@mjansen401
Created May 9, 2011 23:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mjansen401/963641 to your computer and use it in GitHub Desktop.
Save mjansen401/963641 to your computer and use it in GitHub Desktop.
_board.html.erb_spec.rb
require 'spec_helper'
describe "games/_board.html.erb" do
before(:each) do
@ttt = mock(TicTacToe)
stub_template "games/_square.html.erb" => "<square/>"
end
it "displays 9 squares for a 3x3 board" do
render
assert_select "square", 9
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment