summaryrefslogtreecommitdiff
path: root/spec/views/games/show.html.erb_spec.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/views/games/show.html.erb_spec.rb')
-rw-r--r--spec/views/games/show.html.erb_spec.rb23
1 files changed, 23 insertions, 0 deletions
diff --git a/spec/views/games/show.html.erb_spec.rb b/spec/views/games/show.html.erb_spec.rb
new file mode 100644
index 0000000..fb75ad6
--- /dev/null
+++ b/spec/views/games/show.html.erb_spec.rb
@@ -0,0 +1,23 @@
+require 'spec_helper'
+
+describe "games/show" do
+ before(:each) do
+ @game = assign(:game, stub_model(Game,
+ :name => "MyText",
+ :players_per_team => 1,
+ :teams_per_match => 2,
+ :set_rounds => 3,
+ :randomized_teams => 4
+ ))
+ end
+
+ it "renders attributes in <p>" do
+ render
+ # Run the generator again with the --webrat flag if you want to use webrat matchers
+ rendered.should match(/MyText/)
+ rendered.should match(/1/)
+ rendered.should match(/2/)
+ rendered.should match(/3/)
+ rendered.should match(/4/)
+ end
+end