From f61ac899479543859cab67e4ad833284dbf982e9 Mon Sep 17 00:00:00 2001 From: Santiago Pastorino Date: Tue, 22 Jun 2010 16:00:02 -0300 Subject: Avoid method redefined warning MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: José Valim --- activerecord/test/cases/active_schema_test_postgresql.rb | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/activerecord/test/cases/active_schema_test_postgresql.rb b/activerecord/test/cases/active_schema_test_postgresql.rb index 4f04c6735c..f106e14319 100644 --- a/activerecord/test/cases/active_schema_test_postgresql.rb +++ b/activerecord/test/cases/active_schema_test_postgresql.rb @@ -10,7 +10,10 @@ class PostgresqlActiveSchemaTest < Test::Unit::TestCase end def teardown - ActiveRecord::ConnectionAdapters::PostgreSQLAdapter.send(:alias_method, :execute, :real_execute) + ActiveRecord::ConnectionAdapters::PostgreSQLAdapter.class_eval do + remove_method :execute + alias_method :execute, :real_execute + end end def test_create_database_with_encoding -- cgit v1.2.3