]> source.dussan.org Git - redmine.git/commitdiff
Rails4: replace deprecated Relation#first with finder options at ApiTest::VersionsTest
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Fri, 10 Jan 2014 12:24:19 +0000 (12:24 +0000)
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Fri, 10 Jan 2014 12:24:19 +0000 (12:24 +0000)
git-svn-id: http://svn.redmine.org/redmine/trunk@12611 e93f8b46-1217-0410-a6f0-8f06a7374b81

test/integration/api_test/versions_test.rb

index 782ad4c8b7d51cc5f59b1998db27fcc26da00df8..e99d98e94f969828719203764230ea4b26cdcfa7 100644 (file)
@@ -92,7 +92,7 @@ class Redmine::ApiTest::VersionsTest < Redmine::ApiTest::Base
         }, credentials('jsmith')
     end
 
-    version = Version.first(:order => 'id DESC')
+    version = Version.order('id DESC').first
     assert_equal 'API test', version.name
     assert_equal 'Some value', version.custom_field_value(field)