aboutsummaryrefslogtreecommitdiffstats
path: root/railties/helpers
diff options
context:
space:
mode:
authorJeremy Kemper <jeremy@bitsweat.net>2008-06-15 16:21:32 -0700
committerJeremy Kemper <jeremy@bitsweat.net>2008-06-15 16:21:32 -0700
commit09c70a0c03aa755a66dc94ebb2b98b283c7137c9 (patch)
tree33008fcd1b46299bd0155afd19cffc05c3dba032 /railties/helpers
parent59b2daba4f2d1eadabd3e89299114f0d77ae454d (diff)
downloadrails-09c70a0c03aa755a66dc94ebb2b98b283c7137c9.tar.gz
rails-09c70a0c03aa755a66dc94ebb2b98b283c7137c9.tar.bz2
rails-09c70a0c03aa755a66dc94ebb2b98b283c7137c9.zip
Use test/performance/test_helper to do test setup then boost log level and turn on caching
Diffstat (limited to 'railties/helpers')
-rw-r--r--railties/helpers/performance_test.rb5
-rw-r--r--railties/helpers/performance_test_helper.rb6
2 files changed, 7 insertions, 4 deletions
diff --git a/railties/helpers/performance_test.rb b/railties/helpers/performance_test.rb
index d39f639305..7c89816570 100644
--- a/railties/helpers/performance_test.rb
+++ b/railties/helpers/performance_test.rb
@@ -1,7 +1,4 @@
-ENV['RAILS_ENV'] ||= 'test'
-require "#{File.dirname(__FILE__)}/../../config/environment"
-require 'test/unit'
-require 'action_controller/performance_test'
+require 'performance/test_helper'
# Profiling results for each test method are written to tmp/performance.
class BrowsingTest < ActionController::PerformanceTest
diff --git a/railties/helpers/performance_test_helper.rb b/railties/helpers/performance_test_helper.rb
new file mode 100644
index 0000000000..3c4c7fb740
--- /dev/null
+++ b/railties/helpers/performance_test_helper.rb
@@ -0,0 +1,6 @@
+require 'test_helper'
+require 'action_controller/performance_test'
+
+ActionController::Base.perform_caching = true
+ActiveSupport::Dependencies.mechanism = :require
+Rails.logger.level = ActiveSupport::BufferedLogger::INFO