aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test/cases/timestamp_test.rb
diff options
context:
space:
mode:
authorRafael Mendonça França <rafaelmfranca@gmail.com>2012-08-15 11:28:22 -0300
committerRafael Mendonça França <rafaelmfranca@gmail.com>2012-08-15 11:58:41 -0300
commit8055cd65688d5aee9bf756c8483f2c30f75d06cc (patch)
treec7956934bb7672074e6a06c6f0611530ee5507df /activerecord/test/cases/timestamp_test.rb
parent786713a3abc375fab4d5c2f6f62a878c2ab51022 (diff)
downloadrails-8055cd65688d5aee9bf756c8483f2c30f75d06cc.tar.gz
rails-8055cd65688d5aee9bf756c8483f2c30f75d06cc.tar.bz2
rails-8055cd65688d5aee9bf756c8483f2c30f75d06cc.zip
Do not use update_column where update_attribute is not interchangeable
Revert "Deprecate update_attribute." This reverts commit b081f6b59fb3f15d12043072ad9b331ffd2bc56e. Reason: Since the new deprecation policy we removed the deprecation of update_attribute but we didn't reverted the changes to use update_column. Fixes #7306
Diffstat (limited to 'activerecord/test/cases/timestamp_test.rb')
-rw-r--r--activerecord/test/cases/timestamp_test.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/activerecord/test/cases/timestamp_test.rb b/activerecord/test/cases/timestamp_test.rb
index c965371a49..28543a5a3a 100644
--- a/activerecord/test/cases/timestamp_test.rb
+++ b/activerecord/test/cases/timestamp_test.rb
@@ -11,7 +11,7 @@ class TimestampTest < ActiveRecord::TestCase
def setup
@developer = Developer.order(:id).first
- @developer.update_column(:updated_at, Time.now.prev_month)
+ @developer.update_attribute(:updated_at, Time.now.prev_month)
@previously_updated_at = @developer.updated_at
end
@@ -133,7 +133,7 @@ class TimestampTest < ActiveRecord::TestCase
pet = Pet.first
owner = pet.owner
- owner.update_column(:happy_at, 3.days.ago)
+ owner.update_attribute(:happy_at, 3.days.ago)
previously_owner_updated_at = owner.updated_at
pet.name = "I'm a parrot"