Permalink
Browse files

Correct parameter access.

* The params as supplied pass born in authors[0] but not authors[1] so it seems like the test isn't covering what it should be covering.
  • Loading branch information...
1 parent fb0c845 commit 45d6944afa5ec410535f6d36c4354d215b4090c3 @parndt parndt committed Sep 19, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 actionpack/test/controller/parameters/nested_parameters_test.rb
@@ -28,7 +28,7 @@ class NestedParametersTest < ActiveSupport::TestCase
assert_equal "Christopher Marlowe", permitted[:book][:authors][1][:name]
assert_equal 200, permitted[:book][:details][:pages]
assert_nil permitted[:book][:details][:genre]
- assert_nil permitted[:book][:authors][1][:born]
+ assert_nil permitted[:book][:authors][0][:born]
assert_nil permitted[:magazine]
end

0 comments on commit 45d6944

Please sign in to comment.