diff options
Diffstat (limited to 'activerecord/test/models/parrot.rb')
-rw-r--r-- | activerecord/test/models/parrot.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/activerecord/test/models/parrot.rb b/activerecord/test/models/parrot.rb index 5b693664d4..1e5f9285a8 100644 --- a/activerecord/test/models/parrot.rb +++ b/activerecord/test/models/parrot.rb @@ -13,6 +13,11 @@ class Parrot < ActiveRecord::Base def cancel_save_callback_method throw(:abort) end + + before_update :increment_updated_count + def increment_updated_count + self.updated_count += 1 + end end class LiveParrot < Parrot |