]> source.dussan.org Git - redmine.git/commitdiff
Rails4: replace deprecated Relation#update_all at QueryTest
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Thu, 9 Jan 2014 04:24:24 +0000 (04:24 +0000)
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Thu, 9 Jan 2014 04:24:24 +0000 (04:24 +0000)
git-svn-id: http://svn.redmine.org/redmine/trunk@12555 e93f8b46-1217-0410-a6f0-8f06a7374b81

test/unit/query_test.rb

index db8a497480e8cbb01c3df7e4b3c2ce76b4daad17..91f9f3dc1836c592187fd60682689520d0c27f01 100644 (file)
@@ -209,8 +209,7 @@ class QueryTest < ActiveSupport::TestCase
   end
 
   def test_operator_is_on_float
-    Issue.update_all("estimated_hours = 171.2", "id=2")
-
+    Issue.where(:id => 2).update_all("estimated_hours = 171.2")
     query = IssueQuery.new(:name => '_')
     query.add_filter('estimated_hours', '=', ['171.20'])
     issues = find_issues_with_query(query)