Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Remove test case also related to the belongs_to touch feature

  • Loading branch information...
commit e58f11683003ec1515113103895e18a8c9003aa3 1 parent 7389df1
@dhh dhh authored
Showing with 0 additions and 20 deletions.
  1. +0 −20 activerecord/test/cases/timestamp_test.rb
View
20 activerecord/test/cases/timestamp_test.rb
@@ -176,26 +176,6 @@ def self.name; 'Toy'; end
assert_not_equal time, owner.updated_at
end
- def test_clearing_association_touches_the_old_record
- klass = Class.new(ActiveRecord::Base) do
- def self.name; 'Toy'; end
- belongs_to :pet, touch: true
- end
-
- toy = klass.find(1)
- pet = toy.pet
- time = 3.days.ago.at_beginning_of_hour
-
- pet.update_columns(updated_at: time)
-
- toy.pet = nil
- toy.save!
-
- pet.reload
-
- assert_not_equal time, pet.updated_at
- end
-
def test_timestamp_attributes_for_create
toy = Toy.first
assert_equal toy.send(:timestamp_attributes_for_create), [:created_at, :created_on]
Please sign in to comment.
Something went wrong with that request. Please try again.