Permalink
Browse files

moving logger test to its own file

  • Loading branch information...
1 parent bc276fb commit 974a6402d70fa6bb1ecfc43b4925717b474df4d0 @tenderlove tenderlove committed Jan 11, 2012
Showing with 17 additions and 13 deletions.
  1. +17 −0 activerecord/test/cases/migration/logger_test.rb
  2. +0 −13 activerecord/test/cases/migration_test.rb
@@ -0,0 +1,17 @@
+require "cases/helper"
+
+module ActiveRecord
+ class Migration
+ class LoggerTest < ActiveRecord::TestCase
+ def test_migration_should_be_run_without_logger
+ previous_logger = ActiveRecord::Base.logger
+ ActiveRecord::Base.logger = nil
+ assert_nothing_raised do
+ ActiveRecord::Migrator.migrate(MIGRATIONS_ROOT + "/valid")
+ end
+ ensure
+ ActiveRecord::Base.logger = previous_logger
+ end
+ end
+ end
+end
@@ -1238,19 +1238,6 @@ def with_env_tz(new_tz = 'US/Eastern')
ensure
old_tz ? ENV['TZ'] = old_tz : ENV.delete('TZ')
end
-
-end
-
-class MigrationLoggerTest < ActiveRecord::TestCase
- def test_migration_should_be_run_without_logger
- previous_logger = ActiveRecord::Base.logger
- ActiveRecord::Base.logger = nil
- assert_nothing_raised do
- ActiveRecord::Migrator.migrate(MIGRATIONS_ROOT + "/valid")
- end
- ensure
- ActiveRecord::Base.logger = previous_logger
- end
end
class InterleavedMigrationsTest < ActiveRecord::TestCase

0 comments on commit 974a640

Please sign in to comment.