From ae242b0d23df2893f398fb2ec97ba502b7bf361b Mon Sep 17 00:00:00 2001 From: Jeremy Kemper Date: Tue, 29 May 2007 08:29:33 +0000 Subject: Workaround test isolation failure with Task.attr_protected :starting. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6892 5ecf4fe2-1ee6-0310-87b1-e25e094e27de --- activerecord/test/date_time_test.rb | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/activerecord/test/date_time_test.rb b/activerecord/test/date_time_test.rb index 340026ecc3..2624fa0a78 100644 --- a/activerecord/test/date_time_test.rb +++ b/activerecord/test/date_time_test.rb @@ -5,7 +5,11 @@ require 'fixtures/task' class DateTimeTest < Test::Unit::TestCase def test_saves_both_date_and_time now = 200.years.ago.to_datetime - task = Task.create!(:starting => now) + + task = Task.new + task.starting = now + task.save! + assert_equal now, Task.find(task.id).starting end -- cgit v1.2.3