mirror of
https://github.com/TracksApp/tracks.git
synced 2025-09-22 05:50:47 +02:00
Compare items of the same type
Co-Authored-By: Dan Rice <dnrce@users.noreply.github.com>
This commit is contained in:
parent
908f021aa5
commit
6e48ce6594
1 changed files with 2 additions and 2 deletions
|
@ -6,13 +6,13 @@ class TodoCreateParamsHelperTest < ActiveSupport::TestCase
|
|||
def test_works_with_request_as_root_hash_entry
|
||||
params = ActionController::Parameters.new({'request' => { 'todo' => { 'description' => 'foo'}}})
|
||||
params_helper = Todos::TodoCreateParamsHelper.new(params, users(:admin_user))
|
||||
assert_equal({'description' => 'foo'}, params_helper.attributes)
|
||||
assert_equal({'description' => 'foo'}, params_helper.attributes.to_h)
|
||||
end
|
||||
|
||||
def test_works_with_todo_as_root_hash_entry
|
||||
params = ActionController::Parameters.new({ 'todo' => { 'description' => 'foo'}})
|
||||
params_helper = Todos::TodoCreateParamsHelper.new(params, users(:admin_user))
|
||||
assert_equal({'description' => 'foo'}, params_helper.attributes)
|
||||
assert_equal({'description' => 'foo'}, params_helper.attributes.to_h)
|
||||
end
|
||||
|
||||
def test_show_from_accessor
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue