summaryrefslogtreecommitdiffstats
path: root/test/test_helper.rb
diff options
context:
space:
mode:
authorGo MAEDA <maeda@farend.jp>2023-01-01 07:13:39 +0000
committerGo MAEDA <maeda@farend.jp>2023-01-01 07:13:39 +0000
commit1481c721a222ccf05a43ae98d1cf7730314a13d5 (patch)
tree7ffacec036458fd198e7cbf6f5ae72d7cc7eca3e /test/test_helper.rb
parent92bd67c279516f339866e95c702b39cee325ef05 (diff)
downloadredmine-1481c721a222ccf05a43ae98d1cf7730314a13d5.tar.gz
redmine-1481c721a222ccf05a43ae98d1cf7730314a13d5.zip
Use `require_relative` instead of `require File.expand_path(..., __FILE__)` (#38093).
Patch by Go MAEDA. git-svn-id: https://svn.redmine.org/redmine/trunk@22016 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/test_helper.rb')
-rw-r--r--test/test_helper.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/test_helper.rb b/test/test_helper.rb
index aa6470b2f..bd073ef74 100644
--- a/test/test_helper.rb
+++ b/test/test_helper.rb
@@ -19,7 +19,7 @@
if ENV["COVERAGE"]
require 'simplecov'
- require File.expand_path(File.dirname(__FILE__) + "/coverage/html_formatter")
+ require_relative 'coverage/html_formatter'
SimpleCov.formatter = Redmine::Coverage::HtmlFormatter
SimpleCov.start 'rails'
end
@@ -27,10 +27,10 @@ end
$redmine_test_ldap_server = ENV['REDMINE_TEST_LDAP_SERVER'] || '127.0.0.1'
ENV["RAILS_ENV"] = "test"
-require File.expand_path(File.dirname(__FILE__) + "/../config/environment")
+require_relative '../config/environment'
require 'rails/test_help'
-require File.expand_path(File.dirname(__FILE__) + '/object_helpers')
+require_relative 'object_helpers'
include ObjectHelpers
require 'net/ldap'