mirror of
https://github.com/github/rails.git
synced 2026-04-26 03:00:59 -04:00
Fix broken scaffolding tests [#1889 state:committed]
Signed-off-by: David Heinemeier Hansson <david@loudthinking.com>
This commit is contained in:
committed by
David Heinemeier Hansson
parent
9b4aa9bcd9
commit
4866ce45d0
@@ -19,7 +19,7 @@ class RailsScaffoldGeneratorTest < GeneratorTestCase
|
||||
assert_generated_controller_for :products do |f|
|
||||
|
||||
assert_has_method f, :index do |name, m|
|
||||
assert_match /@products = Product\.find\(:all\)/, m, "#{name} should query products table"
|
||||
assert_match /@products = Product\.all/, m, "#{name} should query products table"
|
||||
end
|
||||
|
||||
assert_has_method f, :show, :edit, :update, :destroy do |name, m|
|
||||
@@ -71,7 +71,7 @@ class RailsScaffoldGeneratorTest < GeneratorTestCase
|
||||
assert_generated_controller_for :products do |f|
|
||||
|
||||
assert_has_method f, :index do |name, m|
|
||||
assert_match /@products = Product\.find\(:all\)/, m, "#{name} should query products table"
|
||||
assert_match /@products = Product\.all/, m, "#{name} should query products table"
|
||||
end
|
||||
|
||||
assert_has_method f, :show, :edit, :update, :destroy do |name, m|
|
||||
|
||||
Reference in New Issue
Block a user