aboutsummaryrefslogtreecommitdiffstats
path: root/railties/helpers/test_helper.rb
diff options
context:
space:
mode:
Diffstat (limited to 'railties/helpers/test_helper.rb')
-rw-r--r--railties/helpers/test_helper.rb5
1 files changed, 4 insertions, 1 deletions
diff --git a/railties/helpers/test_helper.rb b/railties/helpers/test_helper.rb
index d177ec3515..5328ccdf5f 100644
--- a/railties/helpers/test_helper.rb
+++ b/railties/helpers/test_helper.rb
@@ -1,5 +1,8 @@
ENV["RAILS_ENV"] = "test"
-require File.dirname(__FILE__) + "/../config/environment"
+
+# Expand the path to environment so that Ruby does not load it multiple times
+# File.expand_path can be removed if Ruby 1.9 is in use.
+require File.expand_path(File.dirname(__FILE__) + "/../config/environment")
require 'application'
require 'test/unit'