[前][次][番号順一覧][スレッド一覧]

ruby-changes:67039

From: aycabta <ko1@a...>
Date: Wed, 4 Aug 2021 18:30:08 +0900 (JST)
Subject: [ruby-changes:67039] aba10ea61e (master): Add a load path to require 'helper'

https://git.ruby-lang.org/ruby.git/commit/?id=aba10ea61e

From aba10ea61e0f837bdca0e98f8e1e6fe7666a89b1 Mon Sep 17 00:00:00 2001
From: aycabta <aycabta@g...>
Date: Tue, 3 Aug 2021 01:40:26 +0900
Subject: Add a load path to require 'helper'

---
 test/readline/test_readline.rb | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/test/readline/test_readline.rb b/test/readline/test_readline.rb
index c2f1839..a5d2e22 100644
--- a/test/readline/test_readline.rb
+++ b/test/readline/test_readline.rb
@@ -479,7 +479,7 @@ module BasetestReadline https://github.com/ruby/ruby/blob/trunk/test/readline/test_readline.rb#L479
     omit unless respond_to?(:assert_ruby_status)
     code = <<-"end;"
       require 'readline'
-      require 'test/readline/helper'
+      require 'helper'
       #{
         if defined?(TestReadline) && self.class == TestReadline
           "use_ext_readline"
@@ -507,7 +507,8 @@ module BasetestReadline https://github.com/ruby/ruby/blob/trunk/test/readline/test_readline.rb#L507
     f.close
     f.open
     asserted = false
-    log, status = EnvUtil.invoke_ruby([path], "", true, :merge_to_stdout) do |_in, _out, _, pid|
+    current_dir = File.expand_path("..", __FILE__)
+    log, status = EnvUtil.invoke_ruby(["-I#{current_dir}", path], "", true, :merge_to_stdout) do |_in, _out, _, pid|
       Timeout.timeout(4) do
         log = String.new
         while c = _out.read(1)
-- 
cgit v1.1


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]