Modifying the mash tournament schema a touch and adding a slew of scaffold-y stuff
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
require 'spec_helper'
|
||||
|
||||
describe "/mash_tournaments/edit.html.erb" do
|
||||
include MashTournamentsHelper
|
||||
|
||||
before(:each) do
|
||||
assigns[:mash_tournament] = @mash_tournament = stub_model(MashTournament,
|
||||
:new_record? => false
|
||||
)
|
||||
end
|
||||
|
||||
it "renders the edit mash_tournament form" do
|
||||
render
|
||||
|
||||
response.should have_tag("form[action=#{mash_tournament_path(@mash_tournament)}][method=post]") do
|
||||
end
|
||||
end
|
||||
end
|
@@ -0,0 +1,16 @@
|
||||
require 'spec_helper'
|
||||
|
||||
describe "/mash_tournaments/index.html.erb" do
|
||||
include MashTournamentsHelper
|
||||
|
||||
before(:each) do
|
||||
assigns[:mash_tournaments] = [
|
||||
stub_model(MashTournament),
|
||||
stub_model(MashTournament)
|
||||
]
|
||||
end
|
||||
|
||||
it "renders a list of mash_tournaments" do
|
||||
render
|
||||
end
|
||||
end
|
@@ -0,0 +1,18 @@
|
||||
require 'spec_helper'
|
||||
|
||||
describe "/mash_tournaments/new.html.erb" do
|
||||
include MashTournamentsHelper
|
||||
|
||||
before(:each) do
|
||||
assigns[:mash_tournament] = stub_model(MashTournament,
|
||||
:new_record? => true
|
||||
)
|
||||
end
|
||||
|
||||
it "renders new mash_tournament form" do
|
||||
render
|
||||
|
||||
response.should have_tag("form[action=?][method=post]", mash_tournaments_path) do
|
||||
end
|
||||
end
|
||||
end
|
@@ -0,0 +1,12 @@
|
||||
require 'spec_helper'
|
||||
|
||||
describe "/mash_tournaments/show.html.erb" do
|
||||
include MashTournamentsHelper
|
||||
before(:each) do
|
||||
assigns[:mash_tournament] = @mash_tournament = stub_model(MashTournament)
|
||||
end
|
||||
|
||||
it "renders attributes in <p>" do
|
||||
render
|
||||
end
|
||||
end
|
Reference in New Issue
Block a user