diff options
Diffstat (limited to 'activerecord/test/migrations')
-rw-r--r-- | activerecord/test/migrations/magic/1_currencies_have_symbols.rb | 12 | ||||
-rw-r--r-- | activerecord/test/migrations/version_check/20131219224947_migration_version_check.rb | 8 |
2 files changed, 20 insertions, 0 deletions
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 diff --git a/activerecord/test/migrations/version_check/20131219224947_migration_version_check.rb b/activerecord/test/migrations/version_check/20131219224947_migration_version_check.rb new file mode 100644 index 0000000000..9d46485a31 --- /dev/null +++ b/activerecord/test/migrations/version_check/20131219224947_migration_version_check.rb @@ -0,0 +1,8 @@ +class MigrationVersionCheck < ActiveRecord::Migration + def self.up + raise "incorrect migration version" unless version == 20131219224947 + end + + def self.down + end +end |