aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test
diff options
context:
space:
mode:
authorCarlos Kozuszko <carlos@insignia4u.com>2009-01-04 20:22:53 -0200
committerMichael Koziarski <michael@koziarski.com>2009-01-16 10:00:39 +1300
commitc891d685de9a729332836751c1293770b86a1b52 (patch)
treed17e38e746c52eca357e35892ec180236715495f /activerecord/test
parent9bcf01b23c25e640da7908ac8b1b49fbf7d2e51a (diff)
downloadrails-c891d685de9a729332836751c1293770b86a1b52.tar.gz
rails-c891d685de9a729332836751c1293770b86a1b52.tar.bz2
rails-c891d685de9a729332836751c1293770b86a1b52.zip
Fixing bug on ActiveRecord::Dirty#field_changed? for nullable numeric columns, NULL gets stored in database for blank (i.e. '') values. Only integer columns were considered.
Signed-off-by: Michael Koziarski <michael@koziarski.com> [#1692 state:committed]
Diffstat (limited to 'activerecord/test')
-rw-r--r--activerecord/test/cases/dirty_test.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/test/cases/dirty_test.rb b/activerecord/test/cases/dirty_test.rb
index 10cdbdc622..480a332ef7 100644
--- a/activerecord/test/cases/dirty_test.rb
+++ b/activerecord/test/cases/dirty_test.rb
@@ -58,7 +58,7 @@ class DirtyTest < ActiveRecord::TestCase
assert_equal parrot.name_change, parrot.title_change
end
- def test_nullable_integer_not_marked_as_changed_if_new_value_is_blank
+ def test_nullable_number_not_marked_as_changed_if_new_value_is_blank
pirate = Pirate.new
["", nil].each do |value|