diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2010-01-03 22:27:28 -0800 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2010-01-03 22:27:28 -0800 |
commit | 5e94d3e3ea06e577d97a32eb4b38b61c4ce8ff8f (patch) | |
tree | b89d06302223be67c595e65bffce54357d41a15a /railties/lib/rails/generators/test_unit | |
parent | d7d917335e242f48fae31bc99e6d4ab381244913 (diff) | |
parent | eca11bfdb5d3cf375faf8a24e2dc0cc5abd20f92 (diff) | |
download | rails-5e94d3e3ea06e577d97a32eb4b38b61c4ce8ff8f.tar.gz rails-5e94d3e3ea06e577d97a32eb4b38b61c4ce8ff8f.tar.bz2 rails-5e94d3e3ea06e577d97a32eb4b38b61c4ce8ff8f.zip |
Merge
Diffstat (limited to 'railties/lib/rails/generators/test_unit')
-rw-r--r-- | railties/lib/rails/generators/test_unit/scaffold/templates/functional_test.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/railties/lib/rails/generators/test_unit/scaffold/templates/functional_test.rb b/railties/lib/rails/generators/test_unit/scaffold/templates/functional_test.rb index e4bf4035da..9380aa49b6 100644 --- a/railties/lib/rails/generators/test_unit/scaffold/templates/functional_test.rb +++ b/railties/lib/rails/generators/test_unit/scaffold/templates/functional_test.rb @@ -16,7 +16,7 @@ class <%= controller_class_name %>ControllerTest < ActionController::TestCase test "should create <%= file_name %>" do assert_difference('<%= class_name %>.count') do - post :create, :<%= file_name %> => { } + post :create, :<%= file_name %> => <%= table_name %>(:one).attributes end assert_redirected_to <%= file_name %>_path(assigns(:<%= file_name %>)) @@ -33,7 +33,7 @@ class <%= controller_class_name %>ControllerTest < ActionController::TestCase end test "should update <%= file_name %>" do - put :update, :id => <%= table_name %>(:one).to_param, :<%= file_name %> => { } + put :update, :id => <%= table_name %>(:one).to_param, :<%= file_name %> => <%= table_name %>(:one).attributes assert_redirected_to <%= file_name %>_path(assigns(:<%= file_name %>)) end |