diff --git a/test/functional/groups_controller_test.rb b/test/functional/groups_controller_test.rb index 67edb9261..0a21b5448 100644 --- a/test/functional/groups_controller_test.rb +++ b/test/functional/groups_controller_test.rb @@ -53,7 +53,7 @@ class GroupsControllerTest < ActionController::TestCase post :create, :group => {:name => 'New group'} end assert_redirected_to '/groups' - group = Group.first(:order => 'id DESC') + group = Group.order('id DESC').first assert_equal 'New group', group.name assert_equal [], group.users end @@ -63,7 +63,7 @@ class GroupsControllerTest < ActionController::TestCase post :create, :group => {:name => 'New group'}, :continue => 'Create and continue' end assert_redirected_to '/groups/new' - group = Group.first(:order => 'id DESC') + group = Group.order('id DESC').first assert_equal 'New group', group.name end