Permalink
Browse files

Improve the error message

  • Loading branch information...
1 parent db1594c commit 1d9309a5b2391b9f839dd23a213031267d03a281 @rafaelfranca rafaelfranca committed Apr 19, 2013
Showing with 2 additions and 2 deletions.
  1. +1 −1 activerecord/lib/active_record/migration.rb
  2. +1 −1 activerecord/test/cases/migration_test.rb
@@ -876,7 +876,7 @@ def run
record_version_state_after_migrating(migration.version)
end
rescue => e
- canceled_msg = use_transaction?(migration) ? ", the migration canceled" : ""
+ canceled_msg = use_transaction?(migration) ? ", this migration was canceled" : ""
raise StandardError, "An error has occurred#{canceled_msg}:\n\n#{e}", e.backtrace
end
end
@@ -277,7 +277,7 @@ def migrate(x)
e = assert_raise(StandardError) { migrator.run }
- assert_equal "An error has occurred, the migration canceled:\n\nSomething broke", e.message
+ assert_equal "An error has occurred, this migration was canceled:\n\nSomething broke", e.message
Person.reset_column_information
assert_not Person.column_methods_hash.include?(:last_name),

0 comments on commit 1d9309a

Please sign in to comment.