From f49d76662ed130ca41806bb3d91666423a411074 Mon Sep 17 00:00:00 2001 From: kennyj Date: Sat, 14 Apr 2012 00:33:25 +0900 Subject: Fix wrong return value from reset_sequence_name method. --- activerecord/test/cases/base_test.rb | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'activerecord/test') diff --git a/activerecord/test/cases/base_test.rb b/activerecord/test/cases/base_test.rb index 5fb49d540f..ef22936e18 100644 --- a/activerecord/test/cases/base_test.rb +++ b/activerecord/test/cases/base_test.rb @@ -1503,7 +1503,11 @@ class BasicsTest < ActiveRecord::TestCase after_seq = Joke.sequence_name assert_not_equal before_columns, after_columns - assert_not_equal before_seq, after_seq unless before_seq.blank? && after_seq.blank? + unless before_seq.nil? && after_seq.nil? + assert_not_equal before_seq, after_seq + assert_equal "cold_jokes_id_seq", before_seq + assert_equal "funny_jokes_id_seq", after_seq + end end def test_dont_clear_sequence_name_when_setting_explicitly @@ -1514,7 +1518,7 @@ class BasicsTest < ActiveRecord::TestCase Joke.table_name = "funny_jokes" after_seq = Joke.sequence_name - assert_equal before_seq, after_seq unless before_seq.blank? && after_seq.blank? + assert_equal before_seq, after_seq unless before_seq.nil? && after_seq.nil? end def test_dont_clear_inheritnce_column_when_setting_explicitly -- cgit v1.2.3