From c3a26c592ca99e92056ae46328ca69336e400882 Mon Sep 17 00:00:00 2001 From: OZAWA Sakuro Date: Sat, 9 Mar 2013 15:37:26 +0900 Subject: Preserve magic comments and content encoding of copied migrations. During insertion of "# This migration comes from ... " comment at the beginning of a migration, presence of magic comment was not considered. --- .../test/migrations/magic/1_currencies_have_symbols.rb | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 activerecord/test/migrations/magic/1_currencies_have_symbols.rb (limited to 'activerecord/test/migrations/magic') diff --git a/activerecord/test/migrations/magic/1_currencies_have_symbols.rb b/activerecord/test/migrations/magic/1_currencies_have_symbols.rb new file mode 100644 index 0000000000..c066c068c2 --- /dev/null +++ b/activerecord/test/migrations/magic/1_currencies_have_symbols.rb @@ -0,0 +1,12 @@ +# coding: ISO-8859-15 + +class CurrenciesHaveSymbols < ActiveRecord::Migration + def self.up + # We use ¤ for default currency symbol + add_column "currencies", "symbol", :string, :default => "¤" + end + + def self.down + remove_column "currencies", "symbol" + end +end -- cgit v1.2.3